ttimbers / MWT_Locomotion_summary_analysis

Other
1 stars 2 forks source link

Locomotion_driver.sh working on my computer #1

Closed ttimbers closed 9 years ago

ttimbers commented 9 years ago

@cloucks @Kwangjin1986 I have made some changes to the Locomotion_driver.sh script we were working on yesterday, please pull from Github to see the changes I made.

I have tested the script with these changes on my computer line by line (replacing the $1, $2 and $3 with the appropriate values) and it worked. I then called the script from the shell giving the appropriate arguments and it also worked! Nice job us! Here is the code I typed into the terminal to call the script:

bash bin/locomotion_driver.sh https://webdav.sfu.ca/files/leroux-lab/leroux-lab-files/ leroux-lab-files/MWT_backup /Users/tiffany/Documents/PostDoc/MWT_130_r1035/analysis/Chore.jar

Please try it on your computer to make sure it works.

Notes on things I changed:

  1. I decided to not move in and out of data, just simply go into data on line 17 do all the work we need to do in that folder, and then move back out of data after that was done (line 40).
  2. Some of our changes to Kwangjin's part yesterday worked very well (e.g. adding "/" to * for deleting only directories), but when I added them to my loop to zip things it broke it. So I reverted these changes back to what I originally had before our meeting yesterday.
  3. My loop to call choreography just worked this morning, not sure why it didn't work yesterday... Please let me know if this works on your computer. Kwangjin, I will email you Chore.jar to install on your computer (fingers crossed it runs on windows - let me know if it doesn't).
  4. The section where we were stuck at the end of the meeting when we were trying to move the folders containing the data files into chore_data and we were getting an error was really close to the solution. We were in fact moving the folders, but we got an error message because the shell also tried to move chore_data into chore_data because its a folder and when we use */ the shell takes the names of all the folders in that directory. So the fix is to have the shell grab the names before we make the directory. Here's how you do that:

mv */ $(mkdir chore_data)

Next meeting (Tuesday next week?) please let me know any kinks you encountered trying to run this script, then we have to work on using regular expressions to split up the first column of merged.file, and then we can start writing code to generate figures.