title: Importing csv files based on list names
body: <p>I'm looking to create a function that will import csv files based on a user input of file names that were created as a list. This is for some data analysis where i will then use pandas to resample the data etc and calculate the percentages of missing data. So far I have:</p>
  <pre><code>parser = lambda x: pd.datetime.strptime(x, '%d/%m/%Y %H:%M')
  number_stations = input(&quot; Please tell how many stations you want to analyse: &quot;)
  list_of_stations_name_number = []
  i = 0
  while i &lt; int(number_stations):
      i += 1
      name = input(&quot; Please the stations name for station number {}: &quot;.format(i))
      list_of_stations_name_number.append(name+ '.csv')
  </code></pre>
  <p>This works as intended whereby, the user will add the name of the stations they are looking to analyse and then will be left with a list located in list_of_stations_name_number. Such as:</p>
  <p><code>list_of_stations_name_number &quot;['DM00115_D.csv', 'DM00117_D.csv', 'DM00118_D.csv', 'DM00121_D.csv', 'DM00129_D.csv']&quot; </code></p>
  <p>Is there any easy way for which i can then redirect to the directory (using os.chdir) and import the csv files based on them matching names. I'm not sure how complicated or simple this would be and am open to try more efficient methods if applicable</p>