Calculate standard deviation


I'm beginner on R studio, and I'm struggling with something that must be quite simple.

I have a .csv file that I imported into R studio and out of this file, I need to calculate the standard deviation of each line. I have been trying to use the as.matrix command but there something I'm missing apparently...

Could you help me out ?

If your data frame consists only of numeric values then you can use to apply function to do the job.

apply(df, 1, sd)

This will call the sd function on each row of a data frame.

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.