R/func.createSample.R

Defines functions func.createSample

func.createSample <-
function( input ){
  n <- nrow(input$modelData)
  #DEFAULT: Leave-One-Out cross validation, number of groups is equal to the number of elements 
  if( input$nFold == n )
    return( 1:n )
  else
    return( sample(1:n) )
}

Try the cvq2 package in your browser

Any scripts or data that you put into this service are public.

cvq2 documentation built on May 2, 2019, 8:29 a.m.