Page MenuHomePhabricator

Incorrect line graph plot appearing for negative values entered in 'Raw data' mode.
Closed, DuplicatePublic0 Estimated Story PointsBUG REPORT

Description

Steps to reproduce:

  1. Open VE
  2. Click on Insert --> Graph
  3. In general settings choose Line Graph as type of graph.
  4. Go to raw mode
  5. Enter the following values of x and y in an attempt to plot the line graph with equation y=-x;

x: 0
y: 0

x: 1
y:-1

x: 2
y:-2

x: 3
y:-3

Observation
The plot does not take the expected shape of a y=-x line graph but just shows a horizontal line.

Video given below:

Event Timeline

This looks like a major functional failure from a VE user's perspective. Would be great to have some feedback on this.

I suspect this is a bug in the Vega being generated by the graph VE plugin

For some reason, the generated vega spec contains "y2": {"scale": "y","value": 0}, - not sure why its there, but removing that would solve the problem.

TheDJ changed the subtype of this task from "Task" to "Bug Report".Jan 20 2022, 3:24 PM
TheDJ moved this task from Backlog to VisualEditor on the MediaWiki-extensions-Graph board.