Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Graph result format #15

Open
JeroenDeDauw opened this issue Feb 27, 2014 · 0 comments
Open

New Graph result format #15

JeroenDeDauw opened this issue Feb 27, 2014 · 0 comments
Labels

Comments

@JeroenDeDauw
Copy link
Member

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant