The Shed is going Social! Join us on FaceBook and Twitter and chime in on the conversation.
|
 |
|
Dev Shed Forums
> Web Design
> JavaScript Development
|
Js data visualization tools
Discuss Js data visualization tools in the JavaScript Development forum on Dev Shed. Js data visualization tools JavaScript Development forum discussing JavaScript and DHTML, AJAX, and issues such as coding cross-browser JavaScript.
|
|
 |
|
|
|
|

Dev Shed Forums Sponsor:
|
|
|

January 14th, 2013, 08:33 PM
|
|
Registered User
|
|
Join Date: Jan 2013
Posts: 2
Time spent in forums: 12 m 6 sec
Reputation Power: 0
|
|
|
Js data visualization tools
First time post! I am brand new to web development and am wondering if someone can help me out. Is it possible to use javascript data visualization tools (see datavisualization.ch for examples) to create graphs, plots, etc. but have them compiled directly to an image file, such as a png?
Intuitively it seems to me if javascript is made for web development, I should still be able to use it "offline" to create the graphics it is typically used to create online.
|

January 14th, 2013, 09:01 PM
|
 |
Contributing User
|
|
|
|
|
Look into learning about the HTML5 Canvas element and how you can use JavaScript to display: graphs, plots, images, and etc., with it.
|

January 14th, 2013, 09:13 PM
|
|
Registered User
|
|
Join Date: Jan 2013
Posts: 2
Time spent in forums: 12 m 6 sec
Reputation Power: 0
|
|
Quote: | Originally Posted by web_loone08 Look into learning about the HTML5 Canvas element and how you can use JavaScript to display: graphs, plots, images, and etc., with it. |
Thanks for the reply. Upon re-reading my post it seems I wasn't very clear in what I'm looking for...
I'm looking to do something along the lines of: - write a program in javascript and use the aforementioned tools
- run the program in my terminal and have it create png or various other image files
Essentially I am trying to figure out how to use the .js tools without opening a web browser. Is this possible? Any ideas?
|

January 14th, 2013, 09:18 PM
|
 |
Contributing User
|
|
|
|
|
JavaScript is a client side scripting language and the browser, is the "client"; so... in short... no. I would look into either C or VB.net or something along those lines; for something like this. You need a program, that is computer based and not browser based... for something like this.
Last edited by web_loone08 : January 14th, 2013 at 09:21 PM.
|

January 14th, 2013, 11:08 PM
|
 |
Lost in code
|
|
|
|
|
It is actually possible, just not very common. JavaScript is an interpreted language, so you need an interpreter program to run JavaScript scripts. Normally, the scripts are run using an interpreter built into the web browser, but there are interpreters designed to run scripts outside of a browser (one example is Rhino).
However, this doesn't necessarily mean that any given JavaScript library will be compatible with it. Most JavaScript libraries are designed to work within an HTML page's document object model, which may not exist within the context of a non-web browser interpreter. So those libraries would not work.
Additionally, unless those libraries are specifically designed to work with a particular interpreter, it's not likely that they would work very well for generating files directly, even if they did run OK within the context provided by the interpreter.
So in summary, you should use some other language for this.
|
Developer Shed Advertisers and Affiliates
| Thread Tools |
Search this Thread |
|
|
|
| Display Modes |
Rate This Thread |
Linear Mode
|
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off
|
|
|
|
|