Skip to content

Radar: category labels only appear when independent axis are used #1261

@Rayffer

Description

@Rayffer

Question Template

ScottPlot Version: 4.1.20

Operating System: Windows

Application Type: WPF

Question: How do I show category name labels in a Radar Chart when independent axis is not enabled?

I want to user radar charts in a way where some data use dependant axis because it makes sense since it's variant types of the same data.

When I disable the independent axis feature, the labels go away while they can be seen when using independent axis, am I doing something wrong?

string[] categoryLabels= new[] { "Lightning", "Poison", "Force", "Slashing", "Bludgeoning", "Piercing" };

double[,] values = {
    { CreatePoint(random), CreatePoint(random), CreatePoint(random), CreatePoint(random), CreatePoint(random), CreatePoint(random)},
    { CreatePoint(random), CreatePoint(random), CreatePoint(random), CreatePoint(random), CreatePoint(random), CreatePoint(random)},
};

wpfPlot.Plot.Clear();
wpfPlot.Configuration.Pan = false;
wpfPlot.Configuration.Zoom = false;
wpfPlot.Plot.Title(title);
var radarPlot = wpfPlot.Plot.AddRadar(values, false, null, true);
radarPlot.AxisType = RadarAxis.Polygon;
radarPlot.WebColor = Color.FromArgb(0x80, 0, 0);
radarPlot.CategoryLabels = categoryLabels;
radarPlot.GroupLabels = groupLabels;
wpfPlot.Plot.SetAxisLimits(new AxisLimits(-2, 2, -2, 2), 0, 0);
wpfPlot.Render();

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions