python (12.9k questions)
javascript (9.2k questions)
reactjs (4.7k questions)
java (4.2k questions)
java (4.2k questions)
c# (3.5k questions)
c# (3.5k questions)
html (3.3k questions)
How to automate adding factors to variables in large data frame in R
I have a large data frame in R with over 200 mostly character variables that I would like to add factors for. I have prepared all levels and labels in an separate data frame. For a certain variable Va...
ebay
Votes: 0
Answers: 2
In R methods to reduce possible error when labeling a factor with many levels
I have a variable with 75 levels, that I would like to format. However, I find it difficult to do so without formatting a level wrong.
As you know creating a factor with its levels is done like this:
...
ebay
Votes: 0
Answers: 2
R: Creating a Table of Factor Levels
I am working with the R programming language. Suppose I have the following data:
var1 <- c("A1", "A2", "A3")
var2 <- c("B1", "B2" )
var_1_a <...

stats_noob
Votes: 0
Answers: 1
Why is levels() not assigning the wrong level to my data?
I'm creating a function that requires users to upload a dataset with a vector of specific characters. Under the hood, I need one column that has the vector remain character, but I also need a separate...
J.Sabree
Votes: 0
Answers: 2