Arcsine transformation of percentage data

Your column ranges from 0 to 100, and the arcsin can only be applied to numbers from 0 to 1. I’m assuming that these percentages should be scaled from 0 to 1 by dividing by 100, and then take the square root of the rescaled number.

mydatatrans <- asin(sqrt(mydata$percentage.of.heads.up.at.halfway / 100))

Results for the mydata in question:

> mydatatrans
 [1] 0.0000000 1.5707963 1.1071487 0.5235988 0.8570431 1.5707963 0.0000000 0.5235988
 [9] 0.7853982 1.5707963 1.5707963 0.9911566 1.5707963 0.3876579 0.5426768 1.5707963
[17] 0.7853982 0.6847192 0.9657860 0.7211213 0.2347441 0.7343093 0.6999833 0.9827854
[25] 0.3876579 0.2691319 0.2485177

Edit:

Changed the data frame name from df to mydata.

Leave a Comment

tech