Advent of Code is back! Unwrap daily challenges to sharpen your Alteryx skills and earn badges along the way! Learn more now.

Alteryx Designer Desktop Ideas

Share your Designer Desktop product ideas - we're listening!
Submitting an Idea?

Be sure to review our Idea Submission Guidelines for more information!

Submission Guidelines

R Tool: More robust read.Alteryx

Can we get a more robust read.Alteryx function for mode="data.frame"?   If it is reading the stream as a data frame, can we have the option  stringsAsFactors = FALSE?

 

I am getting tripped up a lot because the code will execute in R Studio, but will get mysterious behaviours when it runs within the R Tool.   I am manually converting variables to character strings in my R Tool code which I don't have to do in R Studio.   However, I'm not a highly detail oriented R developer, so I will miss variable data type conversions and have spent a lot of time going down the wrong path.  Also, It makes it difficult to maintain two different scripts for the same routine.

 

I have started using the glimpse() function in R Tool code, to help catch some data conversions since it writes the output in the message log.  

 

Rob Campanell

4 Comments
robcamp
7 - Meteor

I have started to include this line of code in my Alteryx R Tool. It will convert all factors in the data frame to character. It uses some of the functions from the various packages in tidyverse.

 

 

library(tidyverse)

df <- read.Alteryx("#1", mode="data.frame")

#-------------- Convert factors to characters ---------------#
df  %>%
map_if(is.factor, as.character)  %>%
as_data_frame -> df

 

Community_Admin
Alteryx
Alteryx
Status changed to: Inactive
 
Community_Admin
Alteryx
Alteryx

The status of this idea has been changed to 'Inactive'. This status indicates that:

 

1. The idea has not had activity in the form of likes or comments in over a year.

2. The idea has not reached ten likes.

3. The idea is still in the 'New Idea' status. 

 

However, this doesn't mean your idea won't be implemented! The Community can still like and comment on this idea. With enough renewed interest, this idea can be brought back into the 'New Idea' status. 

 

Thank you for contributing to the Alteryx Community and the Alteryx Product Idea Boards!

abrasch
8 - Asteroid

I'm hoping this will be revived. I'm also wishing to use more pre-existing R code in Alteryx, but keeping running into issues with object classes.