back-end/threats_monitoring/phishtank-alev.py
def data_frame_to_json(data_frame, filename):
    """ Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file
        @param
            data_frame
            filename:   (str)   the name of the json file to be created
    """

    data_frame_list = list([])
    # break down every data frame row in tuple
    for row in data_frame.itertuples():
        # then keep the necessary stuff, the index timestamp and the accumulated value
        timestamp = high_charts_timestamp(row[0])
        row_list = [timestamp, row[1]]
        # append each list in an other list
        data_frame_list.append(row_list)
    # save list of lists in the file
    with open(filename, 'w') as json_file:
        json.dump(data_frame_list, json_file, indent=4)
 Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file
        @param
            data_frame
            filename:   (str)   the name of the json file to be created
    
Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file
@param
data_frame
filename:   (str)   the name of the json file to be created
Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file @param data_frame filename : ( str ) the name of the json file to be created
def data_frame_to_json(data_frame, filename):
    data_frame_list = list([])
    for row in data_frame.itertuples():
        timestamp = high_charts_timestamp(row[0])
        row_list = [timestamp, row[1]]
        data_frame_list.append(row_list)
    with open(filename, 'w') as json_file:
        json.dump(data_frame_list, json_file, indent=4)
def data_frame_to_json ( data_frame , filename ) : data_frame_list = list ( [ ] ) for row in data_frame . itertuples ( ) : timestamp = high_charts_timestamp ( row [ 0 ] ) row_list = [ timestamp , row [ 1 ] ] data_frame_list . append ( row_list ) with open ( filename , 'w' ) as json_file : json . dump ( data_frame_list , json_file , indent = 4 )
Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file
@param
data_frame
filename:   (str)   the name of the json file to be created
Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file @param data_frame filename : ( str ) the name of the json file to be created
""" Given a data_frame creates a list of smaller lists that contain data frame pairs and stores them in a json file
        @param
            data_frame
            filename:   (str)   the name of the json file to be created
    """ # break down every data frame row in tuple
 # then keep the necessary stuff, the index timestamp and the accumulated value
 # append each list in an other list
 # save list of lists in the file

data_frame
filename