示例#1
0
def single_product_investigated():
    title= 'The number of each product have been tested'
    amount = qst.exec_qst2(data)
    return wv.render_template('answers.html', data=amount.to_html(), title = title )
示例#2
0
def year_of_cheapest_tuna():
    title= 'The year of cheapest tuna was'
    cheapest = qst.exec_qst3(data,df)
    return  wv.render_template('answers.html', data=cheapest.to_html(), title = title)
示例#3
0
def show_data():
    return wv.render_template('answers.html', data=df.to_html())
示例#4
0
def total_products_investigated():
    title= 'The number of products have been tested'
    result = qst.exec_qst1(df)
    return wv.render_template('answers.html', data=result, title = title )
示例#5
0
def top_10_most_expensive_products():
    title = 'The list of top 10 most expensive food products'
    filtered_frame = qst.excec_qst8(data)
    return wv.render_template('answers.html', data=filtered_frame.to_html(), title = title)
示例#6
0
def kiwi_prices_2013():
    title = 'The list of prices for kiwi in 2013 ($)'
    kiwi = qst.excec_qst13(data,df)
    return wv.render_template('answers.html', data=kiwi.to_html(), title = title)
示例#7
0
def home_page():
    return wv.render_template('index.html')
示例#8
0
def most_expensive_product():
    title = 'The most expensive product is'
    expensive = qst.exec_qst6(data)
    return wv.render_template('answers.html', data=expensive.to_html(), title = title)
示例#9
0
def lettuce_prices_2013():
    title = 'The prices for lettuce in 2013'
    lettuce = qst.excec_qst17(data,df)
    return wv.render_template('answers.html', data=lettuce.to_html(), title = title)
示例#10
0
def test():
    title = 'The prices for 500g canned Soup in 2017'
    lettuce = qst.excec_test(data,df)
    return wv.render_template('answers.html', data=lettuce.to_html(), title = title)
示例#11
0
def banana_prices_2013():
    title = 'The prices for bananas in 2013'
    banana = qst.excec_qst16(data,df)
    return wv.render_template('answers.html', data=banana.to_html(), title = title )
示例#12
0
def apple_prices_2013():
    title = 'The prices for apples in 2013'
    apple = qst.excec_qst15(data,df)
    return wv.render_template('answers.html', data=apple.to_html(), title = title)
示例#13
0
def top_10_most_expensive_kiwi():
    title = 'The top 10 most expensive list of kiwi (1 kg)'
    kiwi = qst.excec_qst14(data,df)
    return wv.render_template('answers.html', data=kiwi[:10].to_html(), title= title)
示例#14
0
def year_of_most_expensive_tuna():
    title= 'The year of most expensive tuna was:'
    expensive = qst.exec_qst4(data,df)
    return wv.render_template('answers.html', data=expensive.to_html(), title = title)
示例#15
0
def show_answers():
    return wv.render_template('answers.html')
示例#16
0
def most_cheapest_product():
    title= 'The most cheapest product is'
    cheapest = qst.exec_qst5(data)
    return wv.render_template('answers.html', data=cheapest.to_html(), title = title )
示例#17
0
def plot_page():
    return wv.render_template('plot.html')
示例#18
0
def top_10_cheapest_products():
    title = 'The list of top 10 cheapest food products'
    filtered_frame = qst.excec_qst7(data)
    return wv.render_template('answers.html', data=filtered_frame.to_html(), title = title)
示例#19
0
def info_page():
    return wv.render_template('info.html')
示例#20
0
def average_price_bananas_2012():
    title = 'The average price for 1 kg bananas in 2012 is ($)'
    average = qst.excec_qst9(data,df)
    return wv.render_template('answers.html', data=round(average,3), title = title)
示例#21
0
def price_for_carrots_march_2013():
    title = 'The price for 1 kg carrots in marts 2013 is ($)'
    carrot = qst.excec_qst12(data,df)
    return wv.render_template('answers.html', data=carrot.to_html(), title = title)