Survey banner
The Dataiku Community is moving to a new home! Some short term disruption starting next week: LEARN MORE

Force an output dataset column as string with R.

Level 1
Force an output dataset column as string with R.

How do you proceed to force a column detected as int in a R script to as string in output in order to preserve a specific format . Example : input = 06000 give an output dataset = 6000, and i would i input = 06000 which should give an output = 06000.
0 Kudos
1 Reply

Good news, the latest version of DSS (3.1) now includes this feature.

You can either:

* Force the dataframe to respect the storage schema of the DSS dataset by using

dkuReadDataset("mydataset", inferColClassesFromData=FALSE)

* Force the col class for a set of columns:

dkuReadDataset("mydataset", colClasses=c(mycolumn = "character"))
0 Kudos


Labels (3)
A banner prompting to get Dataiku