You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to create a new Graph result format, where one could create a number of predefined graph types which all have slightly different input arguments.
So there would probably be a parameter which defines what graph it should use, and then after the graph has been determined. It should process the graphs own parameter definitions which is only used within that graph.
The mw code would look something along the lines of the following:
As far as i understand each result format is a class which subclasses SemanticResultPrinter.
I've looked around in the code in SemanticResultPrinter to see if i can actually get the raw input arguments (unprocessed) however to no avail.
Which basically makes me think my approach impossible. The only other solution i could think of is to prefix all the graphs parameters with its own identifierm however this wouldn't be as elegant. But it would prevent parameter definition collisions.
Posting an email from Kim Eik:
I'm trying to create a new Graph result format, where one could create a number of predefined graph types which all have slightly different input arguments.
So there would probably be a parameter which defines what graph it should use, and then after the graph has been determined. It should process the graphs own parameter definitions which is only used within that graph.
The mw code would look something along the lines of the following:
ask: [[Category:...]]
|?Property
|format=highcharts
|graph=frequency histogram
|bins=100 <--- graph parameter
As far as i understand each result format is a class which subclasses SemanticResultPrinter.
I've looked around in the code in SemanticResultPrinter to see if i can actually get the raw input arguments (unprocessed) however to no avail.
Which basically makes me think my approach impossible. The only other solution i could think of is to prefix all the graphs parameters with its own identifierm however this wouldn't be as elegant. But it would prevent parameter definition collisions.
An example could be:
ask: [[Category:...]]
|?Property
|format=highcharts
|graph=frequency histogram
|frequency histogram bins=100 <--- graph parameter
Would you happen to know a way around this? Or maybe have an idea for a better solution?
Thanks for your input.
-- Kim
The text was updated successfully, but these errors were encountered: