I use a Flex/ColdFusion/MSSQl combo to take input from users to generate charts for a website . Is this possible in R? I have used RODBC and sqlQuery as a way of producing static graphs but cannot seem to find a way of doing it dynamically. Over to you JU
I use a Flex/ColdFusion/MSSQl combo to take input from users to generate charts for
Share
Of course you can, you can use fantastic Apache module that allows stateless execution of R scripts – RApache. You can define an R script and catch (unserialize) plot parameters (e.g. via JSON or URL encoded string), plot the graph, and load result(s) with AJAX. That’s pretty much what I did in my app.
If you’re not satisfied with R graph capabilities (and I’m sure that’s so not gonna happen), you can try out
googleVisorcanvaspackages. The first one is “only” a library for GoogleVis API for R, and I’m sure you’ll like the later if you’re familiar with HTML5 canvas. Some lads found it useful.So, the final answer is, yes, you can!. You only need to decide whether you’re going to generate graphs on client or server-side. Of course, even if you decide to generate graphs on the client side, you must massage your data in R and return it in serialized form (JSON or XML encoded). I know that ExtJS 4 also has good interface for creating client-side graphs, but I haven’t used it much (read: “at all”).