Swift Charts - outstanding questions


I've yet to truly learn how to read and understand - then interpret the Apple Docs so that I can write new code - and it actually compiles. So my biggest outstanding question is - - -

How do I read/comprehend the Apple Charts Documentation?
I've got nothing but heartache reading the docs.
docs for Charts Framework are improving - but I still have WrapRage.

What's up with Apple's color sense - those objects are not Pink?

Better than CSS?

Have you found that lines plot outside the bounding box of your Chart?
I found that by default the Chart does NOT clip the marks to the assumed plot area of the chart. So I had to go looking for a way to turn on this behavior. It is the Chart modifier:

.clipped(antialiased: true)

Apple Support said it was NOT a bug. Even when the chart's line lays on top of a button, that now cannot be pressed.

Have you got Charts Questions - send me a
TOOT on iosdev.space.

Chart(data) { ... }

Have you noticed that the Chart( data ) { ... } construct is an implicit loop. And since it is a loop over the data... any content in that loop will be repeatly drawn on the plot.

Constant marks - should not be placed inside that loop. Items like RuleMark() are typically a one-off type of item. See: Practice Good Charting Structure. That annotation font for "Average: 68" was not Bold/Strong... it is an artifact of repeated drawing and looping.

I've lost the PLOT...

There is a Charting detail that I don't understand ... yet. There is this plot...

struct Plot<Content> where Content : ChartContent

A mechanism for grouping chart contents into a single entity.

What does it do? What could a stone-age coder like me do with a Chart that contained a Plot... that contained multiple... pieces of content?

Looking for...

I don't know what to call this thing I've been searching for in the Chart API. I want a chart, with multiple Y axis data domains. I want multiple series plotted, but not using the same scale on the Y axis.

Let me find a picture...

I had hopes that the Plot structure was going to do this complex multiple-series chart. My current thinking is to draw multiple Charts in the ZStack { ... } layered on top of each other...

Chart scale inversion...

I've done some hardcore exploring of the Charts API and it still boggles my brain. What is the codex that is used to write such hard-to-understand documentation? How do they manage to write a document that is literately useless?

I didn't notice for months. The coordinate system inversion that Charts naturally does... did you notice that ZERO is at the bottom of your chart Y axis - YEAH! I know - an INVERTED fast one.... sweet Apple!

But here is when I did notice... trying to use and understand the struct PlotDimensionScaleRange object that cannot be instantiated.
Go ahead and try it...

When you do manage to create the Range - Charts will invert the inversion and leave the Zero up at the top of your graph - WHY?

Group-By Charts

How do I create a chart that groups yearly quarterly sales for multiple locations?

You use the position(by:) modifier - of course.