wrote MSelect function for model selection
final changes to two files fncs.R and Normalized_dspan.R