[R] efficient way of aggregating two variables at once

From: John Christie <jc_at_or.psychology.dal.ca>
Date: Tue, 15 May 2007 13:36:06 -0400


Hi,

        I'm working out d' and therefore I'd like to aggregate two variables at once (hits and false alarms). In the raw data frame is subject, stimulus_presence, and response information. I aggregate this into a table now currently by separating out the target_presence=true data and working out a hit rate and then workout out the false alarm rate from the target_presence=false data. Then I cbind the "x" column from the false alarm aggregate to the hit rate data. Then I can also append a dprime column if I wish. I am just inquiring as to whether there is some facility I am missing for aggregating the variables simultaneously or just generating the d' in one step.



R-help_at_stat.math.ethz.ch mailing list
https://stat.ethz.ch/mailman/listinfo/r-help PLEASE do read the posting guide http://www.R-project.org/posting-guide.html and provide commented, minimal, self-contained, reproducible code. Received on Tue 15 May 2007 - 17:42:10 GMT

Archive maintained by Robert King, hosted by the discipline of statistics at the University of Newcastle, Australia.
Archive generated by hypermail 2.2.0, at Tue 15 May 2007 - 18:31:37 GMT.

Mailing list information is available at https://stat.ethz.ch/mailman/listinfo/r-help. Please read the posting guide before posting to the list.