Could someone please point me to some tutorial or provide an example code snippet about how to create a diagram/flowchart in Dart? The simple scenario would be to have couple of elements connectable to each other and possibility to read which one is connected where. There are tons of JS examples but for learning purposes I would like to go the Dart way :)
I've been using a wrapper around an JS GraphViz library for a number of projects.
See https://pub.dartlang.org/packages/pubviz - Here's the output: http://kevmoo.github.io/pubviz/
Also https://pub.dartlang.org/packages/gviz
It's not super interactive or anything, but it's useful when you just want to visualize a graph structure.
Related
I am familiar with Matlab and would like to use what I know to add the functionality I am looking for in my iOS application. The title really says it all, I would like my app to be able to use the mathematics capabilities that matlab provides like integrals, derivatives, cross products, etc. not any graphing or any of that but just basic equation solving things. Is there a way to add this functionality to it while keeping my application agile. I have heard of the matlab coder that allow code to be switched from matlab to c or c++ that could be used for an Xcode project. If this is the best solution, is that a very difficult coder to work with? This is my first application, I have literally been working with Xcode and objective-c for a few weeks but I have the basic framework of my application good to go. I need this to add the real functionality to it and make it very useable. Please go easy on me if any of my questions seem obvious, I'm a nube, I really appreciate your answers.
Josh
As you mentioned, MATLAB Coder can generate C code from your MATLAB function. The header (.h) and source (.c) files can be plugged into your XCode project. The key part of the work is to decide what the input and output of the function should be and how to interface the rest of the XCode project with the Coder-generated function. Also, existing MATLAB code may not be completely compatible with the Coder, so that some modifications to your MATLAB code may be necessary. The Coder has interactive processes that guide you through this process.
If you haven't done so yet, you should start by looking at some examples of MATLAB Coder provided by MathWorks, e.g.,
http://www.mathworks.com/help/coder/examples/c-code-generation-for-a-matlab-kalman-filtering-algorithm.html?prodcode=ME&language=en
I've been programming with Cocos2d for a while now and I'm pretty familiar with it. But when it comes down to Cocos2d-x lua script, I'm having a really hard time understanding and following the structures. The Cocos2d-x lua template comes with a sample script "hello.lua", which is good, I follow through it and understand it no problem. However, bellowing are my questions,
1, In Cocos2d, you can struct a custom CCSprite class and import"SpriteClass.h" in another class that needs it. And in Cocos2d-x lua, you can create the same custom sprite script and access it in another script via require "scriptname", yeah? So, all you need to write is script and no need to create any classes?
2, I want to learn how to bind C++ the lua in Cocos2d-x lua. I posted this question here and got a pretty good answer, but after reading and searching, I still have trouble figure out where is the binding take place. Should I write it in a .ccp class or .lua script? I also trying to find any samples to study from but I found no luck. Can anyone here post any good source to learn or any sample code I can study?
PS: this question isn't the same as the other one I posted. I'm asking how to separate script so that I don't write everything in one script. As well as some example binding codes I can study.
I recently watched great google talks speech about Cling - C++ language interpreter. But I wonder if anyone except people at CERN (where it is developed) are using Cling, and how good it is from non-collider-physics-scientist point of view, can you write desktop apps with it?
There are some videos of uses cases different from the High Energy Physics: http://www.youtube.com/results?search_query=cling+c%2B%2B (I think first couple are the relevant ones)
It has the potential to be very useful, but it is very young. There is no documentation that I could find, no dedicated mailing list, no online tutorials. I was able to get small toy code to run, but couldn't figure out how to use it productively on a large library yet.
Cling project is well established one. You can find more information in their official website cling. They also have a forum
Thanks
Screen shot below, reads data from some database - I think I can get my head around reading data from DB with some RubyOnRails tutorial I am following - but then how should I be able to represent that data in a pretty shape that they want like this picture below?
What tools, frameworks, etc. should I get myself familiar with very quick to be able to represent the data like this?
Since I am should focus on Rails, it would be great if what you suggest is in something that integrate well with Rails too...
Screen shot2: for this one I "think" somehow I can use "Google Charts" but still good to have your suggestions too.
To make charts you use javascript. There is a lot of libraries out there.
Those small charts in the first picture are called sparklelines. They can be made with this jquery plugin
jQuery Sparklines
And this pure javascript tool
sparklines.js
For other charts I think the best free one is the d3 library and spesially the nvd3 library witch is built on top of the d3 library.
There are also some solutions with the Raphaël—JavaScript Library.
One is gRaphaël.
I personally do not like this one, but have a look.
Charting libraries often use SVG's (Scalable Vector Graphics. Go here to learn about SVG and CSS ) to display the charts. And you feed the data from Rails trough JSON.
Rails can render JSON from the controllers and you can use jbuilder "Jbuilder gives you a simple DSL for declaring JSON structures that beats massaging giant hash structures."
I usually end up with a custom class in the lib directory, because charting usually requires a lot of complex queries and handling of data from the database before you can send it to the chart.
You should see these railscasts. railscasts#223 railscasts#223revised
The first uses highcharts (Not free) and the last use morris.js. Morris is rather simple, but in some chases sufficient.
The last one is the best, but I guess you have to get a subscription to see it.
There is a lot to learn here, and that is fun!
I have seen some plotting apps for ios, such as Graph It and Quick Graph. I am wondering what libraries they are using for creating plots and how to integrate those libraries into ios apps. Thanks a lot and happy new year.
I don't know the answer for those specific apps, but I can think of some things for you to look at. One is gnuplot--the trouble here might be getting it into suitable form to use as a library rather than using it as a command-line tool, since AFAIK there is no NSTask or fork()-ing under iOS. Another would be to embed PERL; the only real hard part of plotting is evaluating the expression to be plotted, which is trivial in something like PERL. And of course there are other libraries dedicated to expression evaluation which may be more suitable, depending on exactly what you want to plot.