![]() ![]() Go to that other tab that is matlab, we're going to read in the files.Ĭhallenge! Go through the help documentation and try to find a function that will read files that are comma separated? (should see a bunch of numbers, comma separated) We'll need to open a new terminal tab to actually navigate around the shell.Įach row is a subject, each column is a different timepoint Let's glance through the data we're going to work with. When naming files with dates use the format: YYYY/MM/DD You can preview what your script is doing by using the echo command - which will output the commands that will run.Notes on naming files - try to stick with alphanumeric characters, stay away from spaces in file names, or special characters (e.g., $).> appends to the file (adds to what's already there).> sends to a file (and will overwrite what's there if the file already exists).allow you to specify 'or' in a command e.g., cp *.txt will copy all files that end in A.txt or B.txt.| allows you to concatenate commands in a single line (e.g., wc -l * | sort -n ).sort (sorts files alphabetically -n flag sorts numerically. ![]() it can be used in combination with lots of other commands e.g., mv *.pdf (move all the pdf files to a certain place). wc -l file_name (give just the number of lines in a file).wc filename (give the lines, words & character count for the file).rm -r folder_name (delete files/folders recursively, that folder and everything in it).rm -i (delete, with prompt to confirm deletion).nano (text editor software in the shell).cat (display contents, also concatenate file contents).ls -R (list contents of directory recursively).ls -lh (combine flags, l="long format, way too much info", h="human readable").ls -F molecules/ (lists contents of molecules folder).ls -F (adds a / to folders letters behind dash are flags).whoami (shows the user's current identity).unzip file -> should see a folder called "data".Place files into a folder called "shell-novice" on your desktop.Best practices in scientific computing slideshow.Git history: # This has alos been moved, it is now located here: Shell history: # This has been removed, but see Emily's terminal output below: Instructors: Brad Taber-Thomas and Emily Davenport
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |