0

I have the following user input Code:

# User Run Code Below to: input start day of week 

start_of_week = input ("input value: ")

print ("----------------------------------------------------- ")
print("Your weekly aggregated weather data will start on:" + " " + start_of_week)

Then I enter Monday in the input box and press enter. As a result my start_of_week variable is successfully set to Monday.

I want to run the following code to call and execute another Python script in my jupyter notebook:

import subprocess
if start_of_week == 'Monday':
    subprocess.call(['python', 'fnDerVar_Discrete_Rain&Snow_RangeBucket_12.8.ipynb'])
else:
    subprocess.call(['python', 'fnWSICleanHistPull_HrtoWeek_10.17_Edited_weekenddate_Arch.ipynb'])

However, when I run it...nothing happens. If the code had run my first script successfully (which met my user input condition of Monday), then I should get an output CSV file. However, I don't get one.

Any help is greatly appreciated!

PineNuts0
  • 4,740
  • 21
  • 67
  • 112

0 Answers0