I stetted up a Spyder project where I have codes located in a specific folder and different datas in different folders. Basically, I would like to read those files using the relative path or a simple approach. Let's take the project tree below as example:
I am trying to read "dummy_csv.csv" using "dummy_code.py".
What I am currently doing is this:
import pandas as pd
filepath= "../../../../../dummy_folder02/untitled folder/untitled folder/untitled
folder/dummy_data/dummy_csv.csv"
pd.read_csv(filepath)
I wonder if there is a more elegant/cleaner way of doing this...