Decomposed outlier check in both scripts into its own function, and moved to a percentage-based definition of how many items to check for outlier status
Updated trial-type sorting logic to reflect the (correct) definition of switch-n and nonswitch-n trials, which in both cases hinges on n being the number of NONSWITCH trials directly preceeding the current trial
Revert "Updated trial-type sorting logic to reflect the (correct) definition of switch-n and nonswitch-n trials, which in both cases hinges on n being the number of NONSWITCH trials directly preceeding the current trial"

This reverts commit fae719d2ee964bad4b2c7211d5b26aa3c6de87d3.