Skip to content

error messages

2 messages · Joyce Flynt, Ben Bolker

#
Im doing a project using Rcommander. I have a dataset with 5 variables, BMI being one of them. I would like to find the variance, standard deviation, range, median, etc of BMI. However, everytime I type a command into the script window, (such as var(BMI$BMI,na.rm=TRUE) )an error message pops up saying Object "BMI" not found. I can graph it, work it, do t-test, etc,. It's listed as one of the variables in the data set. So I don't understand why it cant find BMI. Thanks
#
Joyce Flynt <dr.joyceflynt <at> yahoo.com> writes:
It's hard to solve without a *reproducible* example.
Is your data set really called 'BMI'?  (i.e. should you
be saying BMI$BMI, or just BMI (if your data frame is
attached), or mydata$BMI? If your data set *is* called
BMI, does it make a difference if you rename it to e.g. BMIdat?

  What are the results of

ls()

?