Holcombe:fit psychometric functions

From OpenWetWare
Jump to navigationJump to search

Recent members

Alex Holcombe
• Ryo Nakayama


Skills Checklist
Python Programming
Psychopy/VisionEgg Installation Notes
R analysis,plot,stats
Buttonbox with photocell
Programming Cheat Sheets

most recent method, fitting logit glm with variable lapse rate

Use glm with probit. I tried robust glm (glmrob) but it doesn't provide a good measure of deviance (error of the fit), so can't compare different goodness of different fits. modelfree package includes routines for fitting with the appropriate linking function to allow for a lapserate and a guessing rate. I have modified this to yield binomfit_limsAlex

other possibilites



Malte Kuss hosts the R library PsychoFun on his personal webpage rather than CRAN server. So you must download is package, unzip it, and install it by inside R going to Packages&Data->Package Installer->Local Package Directory->Install, go inside the PsychoFun directory you've unzipped, and click Open. I needed to constrain width of psychometric function to be quite narrow. Prior I was using followed lognormal distribution. Then if want mode to be say .1, have to feed it a mean parameter of -2.3 because ln(.1) = -2. Unfortunately the PsychoFun code doesn't allow using a negative parameter for that prior, so I had to change the code. To do so, you go into the downloaded version of PsychoFun folder before you install it, where you can find PsychoFun.R in the R subdirectory. I commented out line 56. Then have to reinstall with Package Installer inside R, "Local Package Directory" option, after in my case first deleting original PsychoFun installation in /Library/Frameworks/R.framework/Versions/2.10/Resources/library/ Technical Report explains many more terms than JoV article: Acceptance rate:Next sample in chain only accepted if quantity on p.481 of JoV paper is good Kinetic, Potential energy from Hamiltonian algorithm


method 2

boot package

modelfree package

boot.ci gives you bootstrapped confidence intervals of various types explained here