File size: 509 Bytes
312b9eb |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 |
import pandas as pd
import altair as alt
def create_area_chart(filtered_data_long, selected_cell):
chart = alt.Chart(filtered_data_long).mark_area().encode(
x=alt.X('timestamp:T', title='Timestamp'),
y=alt.Y('Value:Q', title='RB Used'),
color=alt.Color('RB:N', title='RB Type'),
tooltip=['timestamp:T', 'RB:N', 'Value:Q']
).properties(
width=800,
height=400,
title=f'RB Usage for Cell ID: {selected_cell}'
).interactive()
return chart
|