I am new in R and for my class, I am trying to write the codes for one sample, a one-sided t-test for the alternative B<0. As you probably can understand, weight is the independent variable I want to test.
t.test(Data$weight, alternative = "less", mu = 0, paired = FALSE, var.equal = FALSE)
For some mistake I did, I am receiving a p value=1 where it is certainly should be 0.1.
I know I can find the p-value from the two-sided test but I want to be able to do it this way.
Would you please point out my mistake or suggest a fix, a better option?