In a streamlit app when trying to plot figures with a different format than the standard format I get very bad resolutions.
Example:
import pandas as pd
import numpy as np
import streamlit as st
index = pd.date_range(start='2019-01-01', periods=31)
data = np.random.randint(0,100,size=(len(index)))
df = pd.DataFrame(index=index, data=data)
df.plot(figsize=(25, 5), antialiased=True)
st.pyplot(dpi=100)
Results in a plot like this:
The same plot in a jupyter notebook with the same figsize does not have this issue. Why is this happening and how can I fix this issue?