pwGetDrivingFunctionFromFile


 df = pwGetDrivingFunctionsFromFile(filename, inputType, colNameStimulusIDs,
                                         colNameTime, colNameValues)

 Reads a single driving input functions from a file or a data struct.

 

Arguments

 filename      Either a string comprising the filename of an external xls or txt
               file or a data struct returned by Data_ReadDataFile in order to
               avoid multiple loading of the same file. See example below.

 inputType     'steps', 'linear', 'injection', 'spline'. Compare pwAddU.

 colNameStimulusIDs
               Exact name of the column comprising the stimulus IDs which have
               to start at 1 and must be contiguous. The stimulus ID
               corresponds to a different experimental setting, e.g.
               stimulation with a different dosage or a different patient.

 colNameTime   Exact name of the column comprising the time values.

 colNameValues Exact name of the column comprising the values of the
               driving input function (uValues).


 

Example

 % Loading information from the external file for each input separately

 drivingFunctionInput1 = pwGetDrivingFunctionFromFile(...
        'inputFile.xls', 'linear', 'Stimulus', 'Time', 'ValuesInput1');
 drivingFunctionInput2 = pwGetDrivingFunctionFromFile(...
        'inputFile.xls', 'linear', 'Stimulus', 'Time', 'ValuesInput2');

 % Loading the external file only once

 dataStruct            = Data_ReadDataFile('inputFile.xls');
 drivingFunctionInput1 = pwGetDrivingFunctionFromFile(...
        dataStruct, 'linear', 'Stimulus', 'Time', 'ValuesInput1');
 drivingFunctionInput2 = pwGetDrivingFunctionFromFile(...
        dataStruct, 'linear', 'Stimulus', 'Time', 'ValuesInput2');

See also

pwAddData
pwGetDrivingFunction
pwGetDrivingFunctionCont