import os
import time

dr = os.getcwd()
destdr = 'C:\\Python314'
install = "py -3.14 -m pip install "

library = ['numpy', 'pandas', 'tabulate', 'xlrd', 'xlwt', 'pillow', 'altair',
        'bokeh', 'calplot', 'calmap', 'json5', 'lxml', 'matplotlib',
        'scikit-learn', 'scipy', 'seaborn', 'kaleido', 'openpyxl']

##if not in designated folder, change to designated folder
if dr != destdr:
    os.chdir(destdr)   

## extract files in installation folder, designated c:\python38
for lib in library:
    print("Installing ",lib)        
    cmd = install + lib
    ##print(cmd)
    ##run pip install file 
    os.system(cmd)
    ##snooze for 45 seconds for installation to complete
    time.sleep(45)
