I have been trying to preform both a bartlett's test and an arcsine transformation on some average percentage data. I've tried inputting it different ways and I keep getting the same error message:> head(workingdata)DYAD BEFORE AFTER 1 BG-FL 4.606772 5.787520 2 BG-LL 5.467503 7.847395 3 AD-MV 5.333735 11.107380 4 MM-FL 5.578708 12.063500 5 MM-MV 2.037605 6.415303 6 MM-RM 6.158885 11.911080> bartlett.test(BEFORE ~ AFTER)Error in bartlett.test.default(c(4.606772, 5.467503, 5.333735, 5.578708, : there must be at least 2 observations in each group> asin(BEFORE)[1] NaN NaN NaN NaN NaN NaN NaN Warning message: In asin(BEFORE) : NaNs produced I'm at a loss here and I would greatly appreciate any guidance that could be given me. Thank you! -- Claire Sheller Department of Anthropology Tulane University New Orleans, LA 70118 615-210-9129 [[alternative HTML version deleted]]
Perhaps you need
with(workingdata, asin(BEFORE))
or
asin(workingdata$BEFORE)
_____________________________
Professor Michael Kubovy
University of Virginia
Department of Psychology
USPS: P.O.Box 400400 Charlottesville, VA 22904-4400
Parcels: Room 102 Gilmer Hall
McCormick Road Charlottesville, VA 22903
Office: B011 +1-434-982-4729
Lab: B019 +1-434-982-4751
Fax: +1-434-982-4766
WWW: http://www.people.virginia.edu/~mk9y/
On Apr 30, 2008, at 4:52 PM, Claire Sheller wrote:
> I have been trying to preform both a bartlett's test and an arcsine
> transformation on some average percentage data. I've tried inputting
> it
> different ways and I keep getting the same error message:
>
>> head(workingdata)
> DYAD BEFORE AFTER
> 1 BG-FL 4.606772 5.787520
> 2 BG-LL 5.467503 7.847395
> 3 AD-MV 5.333735 11.107380
> 4 MM-FL 5.578708 12.063500
> 5 MM-MV 2.037605 6.415303
> 6 MM-RM 6.158885 11.911080
>> bartlett.test(BEFORE ~ AFTER)
> Error in bartlett.test.default(c(4.606772, 5.467503, 5.333735,
> 5.578708, :
> there must be at least 2 observations in each group
>> asin(BEFORE)
> [1] NaN NaN NaN NaN NaN NaN NaN
> Warning message:
> In asin(BEFORE) : NaNs produced
>
> I'm at a loss here and I would greatly appreciate any guidance that
> could be
> given me. Thank you!
>
> --
> Claire Sheller
> Department of Anthropology
> Tulane University
> New Orleans, LA 70118
> 615-210-9129
[[alternative HTML version deleted]]
On 4/30/2008 4:52 PM, Claire Sheller wrote:> I have been trying to preform both a bartlett's test and an arcsine > transformation on some average percentage data. I've tried inputting it > different ways and I keep getting the same error message: > >> head(workingdata) > DYAD BEFORE AFTER > 1 BG-FL 4.606772 5.787520 > 2 BG-LL 5.467503 7.847395 > 3 AD-MV 5.333735 11.107380 > 4 MM-FL 5.578708 12.063500 > 5 MM-MV 2.037605 6.415303 > 6 MM-RM 6.158885 11.911080 >> bartlett.test(BEFORE ~ AFTER) > Error in bartlett.test.default(c(4.606772, 5.467503, 5.333735, 5.578708, : > there must be at least 2 observations in each groupbartlett.test() expects the second argument to be "a vector or factor object giving the group for the corresponding elements of x". You seem to have paired samples instead.>> asin(BEFORE) > [1] NaN NaN NaN NaN NaN NaN NaN > Warning message: > In asin(BEFORE) : NaNs producedYou might divide the values by 100 prior to asin().> I'm at a loss here and I would greatly appreciate any guidance that could be > given me. Thank you!-- Chuck Cleland, Ph.D. NDRI, Inc. (www.ndri.org) 71 West 23rd Street, 8th floor New York, NY 10010 tel: (212) 845-4495 (Tu, Th) tel: (732) 512-0171 (M, W, F) fax: (917) 438-0894