Filing and directory manipulation
Managing files and directories is a fundamental skill when working in a Unix-based environment. As a data scientist, you’ll frequently need to create, delete, move, and copy files and directories. Knowing how to use these commands in your daily activities may become a core skill, depending on the systems you are using. However, in a technical interview, these topics might occasionally come up. Therefore, we will only quickly review a few core operations here.
The following list will explain these operations and discuss how to manipulate file and directory contents:
- Creating files: To create a new file, use the
touch
command followed by the name of the file you want to create. For instance, to create a file namedanalysis.py
, you would use the following command:touch analysis.py
- Creating directories: To create a new directory, use the
mkdir
command. For example, to create a directory namednew_data
, use the following:mkdir new_data...