We are celebrating the 10-year anniversary of the Alteryx Community! Learn more and join in on the fun here.
Start Free Trial

Alteryx Designer Desktop Discussions

Find answers, ask questions, and share expertise about Alteryx Designer Desktop and Intelligence Suite.

R Tool Error: Problem with 'mutate()' input ...

nshields
6 - Meteoroid

Hi! I am copying R code straight from R Studio into the R tool on Alteryx and running into the error: Problem with 'mutate()' input 'mapping'. 

 

Here is the code within the R tool:

# Install Libraries
library(tidyverse)

# Read in data
prods <- read.Alteryx("#1", mode="data.frame")

# Clean
prods <- prods %>%
mutate(mapping = case_when(
grepl("Cheese", item_name) ~ "Cream Cheese",
grepl("Cheese Burger", item_name) ~ "Hamburger",
TRUE ~ mapping))

# Write out data
write.Alteryx(prods, 3)

 The data read in (in data frame 'prods') contains only 2 columns: item_name and mapping, each with type V_WString. 

 

Does anybody know why I would be running into this error? This code is error free when run in R Studio with the same data.

 

Thank you!

0 REPLIES 0
Labels
Top Solution Authors