close
Skip to main content
Filter by
Sorted by
Tagged with
0 votes
0 answers
29 views

I am trying to create a horizontal bar chart that consists of a single bar that represents started and finished activities. The bar should start with the 'started' activities followed by the 'finished'...
Yukhnatia's user avatar
3 votes
0 answers
52 views

Goal: color the area above the line using mark_area. Issue: the area appears below the line. Any changes I make to the Y2 channel (in terms of using alt.Y2Value or alt.value) have no effect. Context: ...
Juan Martinez's user avatar
1 vote
0 answers
47 views

I'm following this example from the documentation: import altair as alt from vega_datasets import data source = data.movies() alt.Chart(source).mark_bar().encode( alt.X("IMDB_Rating:Q")...
davemfish's user avatar
  • 321
2 votes
1 answer
103 views

Imagine having the following polars dataframe "df" that contains the temperature of a machine that is either "active" or "inactive": import polars as pl from datetime ...
the_economist's user avatar
1 vote
1 answer
209 views

I've built a dataset in Polars (python), attempting to plot it as a stacked horizontal bar chart using Polars' built-in Altair plot function, however trying to specify a custom sort order for the ...
ExactaBox's user avatar
  • 3,435
Advice
4 votes
4 replies
217 views

I'm trying to create a chart, that looks like a Ridgeplot (for examples see this and this), but has smoothed Area charts with a categorical x-axis as a basis. Why standard Ridgeplot libraries don't ...
MaximJ's user avatar
  • 35
0 votes
1 answer
37 views

Using the wheat dataset from vega_datasets to build a standard bar chart from vega_datasets import data alt.Chart(data.wheat()).mark_bar().encode( alt.X('year:O'), alt.Y('wheat:Q') ) I get ...
cstork's user avatar
  • 586
2 votes
1 answer
80 views

I want to create colored areas in a plot to essentially mark a "region". In matplotlib I could achieve this by manipulating barh: import polars as pl import matplotlib.pyplot as plt aux = ...
Ana Sílvia C. Silva's user avatar
0 votes
0 answers
63 views

I am trying to recreate altair plots to check my setup and it does not plot the axis ticks and labels. Is there a cached config or settings that I need to clear? source = pd.DataFrame({ 'a': ['A', ...
aeroaks's user avatar
1 vote
1 answer
86 views

I made a heatmap with Altair with wide borders between the cells, in Jupyter notebook. When I print it in notebook it looks like it is supposed to - with wide borders, However when I save it as png, ...
Yuli's user avatar
  • 13
0 votes
0 answers
90 views

I've plotted a curve which involved some transform calculations, and now I want to place a vertical rule at a specific x location that stops at the height corresponding to that line. This is what I'...
Juan Martinez's user avatar
1 vote
2 answers
111 views

I have a dataframe with 4 rows, two of which having the same value for the "a" field. I'd like to have a bar chart with 4 bars, one for each row. Trying with Altair source = pd.DataFrame({ ...
MiscBits's user avatar
2 votes
1 answer
93 views

I'm trying to make an area chart of a CDF plot (which should be always increasing), instead I get the result in the image below. import altair as alt import polars as pl _data = pl.DataFrame({"...
Juan Martinez's user avatar
1 vote
1 answer
237 views

I have the following code in Python, using Streamlit as framework: try: native_data = data.copy() # Create Altair chart with native data st.write(f"Debug: Native data type: {type(...
HuLu ViCa's user avatar
  • 5,535
2 votes
1 answer
72 views

I have a layered chart (see below). I want to sort its X axis by values of the Y axis. When my layered chart consist of bars + mark_rule, the sorting works. However, when I replace mark_rule with ...
sasha's user avatar
  • 33

15 30 50 per page
1
2 3 4 5
95