ci_mapping/analysis/descriptive_analysis.py
def annual_citation_sum(data, filename="annual_citation_sum"):
    """Sum of annual citations for CI and AI+CI.

    Args:
        data (`pd.DataFrame`): MAG paper data.
        filename (str): Name of the HTML file to store the plot.

    """
    df = pd.DataFrame(data.groupby(["year", "type"])["citations"].sum()).reset_index()

    # Plotting
    alt.Chart(df).mark_circle(opacity=1, stroke="black", strokeWidth=0.5).encode(
        alt.X("year", axis=alt.Axis(labelAngle=0)),
        alt.Y("type"),
        alt.Size(
            "citations",
            scale=alt.Scale(range=[0, 1500]),
            legend=alt.Legend(title="Citations"),
        ),
        alt.Color("type", legend=None),
    ).properties(
        width=780,
        height=150,
        title="Total citations for CI and AI+CI papers published in a year",
    ).save(
        f"{ci_mapping.project_dir}/reports/figures/{filename}.html"
    )
    logger.info(f"Stored {filename} plot.")
Sum of annual citations for CI and AI+CI.

    Args:
        data (`pd.DataFrame`): MAG paper data.
        filename (str): Name of the HTML file to store the plot.

    
Sum of annual citations for CI and AI+CI.
Sum of annual citations for CI and AI + CI .
def annual_citation_sum(data, filename="annual_citation_sum"):
    df = pd.DataFrame(data.groupby(["year", "type"])["citations"].sum()).reset_index()
    alt.Chart(df).mark_circle(opacity=1, stroke="black", strokeWidth=0.5).encode(
        alt.X("year", axis=alt.Axis(labelAngle=0)),
        alt.Y("type"),
        alt.Size(
            "citations",
            scale=alt.Scale(range=[0, 1500]),
            legend=alt.Legend(title="Citations"),
        ),
        alt.Color("type", legend=None),
    ).properties(
        width=780,
        height=150,
        title="Total citations for CI and AI+CI papers published in a year",
    ).save(
        f"{ci_mapping.project_dir}/reports/figures/{filename}.html"
    )
    logger.info(f"Stored {filename} plot.")
def annual_citation_sum ( data , filename = "annual_citation_sum" ) : df = pd . DataFrame ( data . groupby ( [ "year" , "type" ] ) [ "citations" ] . sum ( ) ) . reset_index ( ) alt . Chart ( df ) . mark_circle ( opacity = 1 , stroke = "black" , strokeWidth = 0.5 ) . encode ( alt . X ( "year" , axis = alt . Axis ( labelAngle = 0 ) ) , alt . Y ( "type" ) , alt . Size ( "citations" , scale = alt . Scale ( range = [ 0 , 1500 ] ) , legend = alt . Legend ( title = "Citations" ) , ) , alt . Color ( "type" , legend = None ) , ) . properties ( width = 780 , height = 150 , title = "Total citations for CI and AI+CI papers published in a year" , ) . save ( f"{ci_mapping.project_dir}/reports/figures/{filename}.html" ) logger . info ( f"Stored {filename} plot." )
Sum of annual citations for CI and AI+CI.
Sum of annual citations for CI and AI + CI .
"""Sum of annual citations for CI and AI+CI.

    Args:
        data (`pd.DataFrame`): MAG paper data.
        filename (str): Name of the HTML file to store the plot.

    """ # Plotting
data
MAG paper data.
MAG paper data .
filename
Name of the HTML file to store the plot.
Name of the HTML file to store the plot .