parseFlyPath.m 353 B

1234567891011
  1. function [experimentDir, flyInd, genotype] = parseFlyPath(flyPath)
  2. experimentDir = regexp(flyPath, '(\d*\.\d\.\w\w)*', 'tokens');
  3. experimentDir = experimentDir{1}{1};
  4. flyInd = regexp(flyPath, '.*fly(\d*)_', 'tokens');
  5. flyInd = str2double(flyInd{1}{1});
  6. genotype = regexp(flyPath, '.*fly\d*_(.*)', 'tokens');
  7. genotype = genotype{1}{1};
  8. end