I am a beginner in Rstudio but I don't really understand how to do some things. I need to create a dataset but do not know how to go about it. Where do I start first?
You can make a data set using the data.frame() function,
DF <- data.frame(Height = rnorm(50, 170, 5), Weight = rnorm(50, 55, 5))
If you want to include two distributions within each column, you can use the c() function to combine them.
DF <- data.frame(Height = c(rnorm(50, 170, 5), rnorm(50, 160, 5)), Weight = c(rnorm(50, 65, 5), rnorm(50, 55, 5))
Thanks for your help!
This topic was automatically closed 21 days after the last reply. New replies are no longer allowed.
If you have a query related to it or one of the replies, start a new topic and refer back with a link.