data/process_data.py
def save_data(dtss, database_filepath):
    """The save_data function save the dataframe to sql database

    Args:
        dtss (DataFrame): the DataFrame to save to sql
        database_filepath (filepath): filepath of the sql database


    Returns: None

    """
    # create engine
    engine = create_engine(f"sqlite:///{database_filepath}", echo=False)

    # save to database
    dtss.to_sql("disasterTable", engine, index=False, if_exists="replace")
The save_data function save the dataframe to sql database

    Args:
        dtss (DataFrame): the DataFrame to save to sql
        database_filepath (filepath): filepath of the sql database


    Returns: None

    
The save_data function save the dataframe to sql database
The save_data function save the dataframe to sql database
def save_data(dtss, database_filepath):
    engine = create_engine(f"sqlite:///{database_filepath}", echo=False)
    dtss.to_sql("disasterTable", engine, index=False, if_exists="replace")
def save_data ( dtss , database_filepath ) : engine = create_engine ( f"sqlite:///{database_filepath}" , echo = False ) dtss . to_sql ( "disasterTable" , engine , index = False , if_exists = "replace" )
The save_data function save the dataframe to sql database
The save_data function save the dataframe to sql database
"""The save_data function save the dataframe to sql database

    Args:
        dtss (DataFrame): the DataFrame to save to sql
        database_filepath (filepath): filepath of the sql database


    Returns: None

    """ # create engine # save to database
dtss
the DataFrame to save to sql
the DataFrame to save to sql
database_filepath
filepath of the sql database
filepath of the sql database