version 1.
This commit is contained in:
parent
3ad17718a9
commit
3c81689788
22
app.py
22
app.py
|
|
@ -23,18 +23,24 @@ radius = indices
|
|||
x = radius * np.cos(theta)
|
||||
y = radius * np.sin(theta)
|
||||
|
||||
df = pd.DataFrame({
|
||||
"x": x,
|
||||
"y": y,
|
||||
"idx": indices,
|
||||
"rand": np.random.randn(num_points),
|
||||
})
|
||||
df = pd.DataFrame(
|
||||
{
|
||||
"x": x,
|
||||
"y": y,
|
||||
"idx": indices,
|
||||
"rand": np.random.randn(num_points),
|
||||
}
|
||||
)
|
||||
|
||||
st.altair_chart(alt.Chart(df, height=700, width=700)
|
||||
st.text("Version 1")
|
||||
|
||||
st.altair_chart(
|
||||
alt.Chart(df, height=700, width=700)
|
||||
.mark_point(filled=True)
|
||||
.encode(
|
||||
x=alt.X("x", axis=None),
|
||||
y=alt.Y("y", axis=None),
|
||||
color=alt.Color("idx", legend=None, scale=alt.Scale()),
|
||||
size=alt.Size("rand", legend=None, scale=alt.Scale(range=[1, 150])),
|
||||
))
|
||||
)
|
||||
)
|
||||
|
|
|
|||
Loading…
Reference in New Issue