Jump to content

pivot_longer is missing from dplyr package in TERR


Adi Lavy

Recommended Posts

I am trying to use the function pivot_longer from the dplyr package but I get an error saying that pivot_longer is not available.

Running on Spotfire 10.10 and TERR 5.1.0, 64 bit on Windows 10 within Parallels virtual machine.

I am using this command which works fine on RStudio with TERR engine:

df %>%

mutate_if(is.numeric,as.character, is.factor, as.character) %>%

pivot_longer(

cols = everything(),

names_to = c('Resource type', 'Input-Output', 'Resource', 'Property', '.value'),

values_to = "val",

values_ptypes = list(val = 'character'),

names_pattern = '(\w.+) \| (\w.+) \| (\w.+) \| (\w.+) \| (\w.+)')and this is the error:

TIBCO Enterprise Runtime for R returned an error The data function 'Bill of Materials expanded (11) (Bill of Materials expanded)' could not be executed.

Error in function_list[[k]](value) : could not find function "pivot_longer"

 

eval(script, envir = .GlobalEnv

eval(script, envir = .GlobalEnv)

withCallingHandlers({ df %>% mutate_if(is.numeric, as.character, is.factor, as.character) %>% pivot_longer(cols = everything(),

 

withVisible(eval(quote(`_fseq`(`_lhs`)), env, env))

val(quote(`_fseq`(`_lhs`)), env, env)

eval(quote(`_fseq`(`_lhs`)), env, env)

`_fseq`(`_lhs`)

freduce(value, `_function_list`)

withVisible(function_list[[k]](value))

function_list[[k]](value)

Link to comment
Share on other sites

  • 3 weeks later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...