I have a data set with weight values in a CSV file. My goal is to find the standard deviation of these values.
I have tried assigning a variable to the file, attaching it, then using the standard deviation function sd()
, to find the standard deviation. In return, I get this error message:
Argument is not Numerical or Logical: returning NA
My file looks like this:
weight.g
54.4
24.2
84.9
56.5
This is the code that I'm using:
brains <- read.csv(file.choose())
attach(brains)
sd(brains)