The question
Given this data
labels,quantity
string1,20
string2,15
string3,10
string4,19
I want to create the following graph in R: Two parallel vertical lines, the one on the left for the labels and the one for the right for the quantitative data. Lines are drawn between the pairs (see image below).
Is there a function in some R package that can create such plots? If not, could you provide some information on how I could do it?
Additional context
The graph shown above was generated by Wikidata by using the following SPARQL query (
It is worth adding that echarts4r
creates html charts - whether that is a benefit or not depends. You can save it to png using htmlwidgets
as described here.