Beispiel #1
0
    def goto_query(self):
        """
        Go to query function
        """
        # destory main GUI
        self.root.destroy()

        # enter query GUI
        query.init()
Beispiel #2
0
def init(schema, coll, pgConn, host, resourceUtil, workspacePath):
    global collections
    collections = coll;

    ensureIndexes(collections)

    files.init(collections, workspacePath)
    ckan.init(pgConn, schema)
    query.init(collections, host)
    vocab.init(schema, collections)
    delete.init(collections, workspacePath)
    workspace.init(collections, resourceUtil, workspacePath)
    mapreduce.init(collections, schema)
    push.init(collections)
import configs
import query
import core_stats
import advanced_stats
import export_list

# Initialize connection to NFLBB
query.init()

# Process and export qb stats csv
qb_list = []
config = configs.qb()
core_stats.generate_position_stats(qb_list, config)
advanced_stats.calc_plyr(qb_list, config['sample_size'], config['cost_baseline'])
export_list.export_to_json(qb_list, 'qb')
export_list.export_to_csv(qb_list, '2016_qb.csv')

# Process and export rb stats csv
rb_list = []
config = configs.rb()
core_stats.generate_position_stats(rb_list, config)
advanced_stats.calc_plyr(rb_list, config['sample_size'], config['cost_baseline'])
export_list.export_to_json(rb_list, 'rb')
export_list.export_to_csv(rb_list, '2016_rb.csv')

# # Process and export wr stats csv
wr_list = []
config = configs.wr()
core_stats.generate_position_stats(wr_list, config)
advanced_stats.calc_plyr(wr_list, config['sample_size'], config['cost_baseline'])
export_list.export_to_json(wr_list, 'wr')