Menu

Create only a plain graphic

Help
Floh1111
2011-06-07
2013-05-09
  • Floh1111

    Floh1111 - 2011-06-07

    Hi,

    I tried to create a plain graphic without timeline and all the other stuff around. I just want to use fixed values and I wanted to change the size of the graphic but I did not find any option to change this or an example of how to do this.

    I´m not verry good in coding Javascript and I can only provide the creapy code I tried:

    var fname='http://netmon.freifunk-ol.de/rrdtool/databases/router_17_interface_batvpn_traffic_rx.rrd';
    FetchBinaryURLAsync(fname,make_plot_handler);
    function make_plot_handler(binary_file) {
        try {
            var i_rrd_data=new RRDFile(binary_file);
        } catch(err) {
            alert("File "+fname+" is not a valid RRD archive!");
        }
        var nrDSs=i_rrd_data.getNrDSs();
        var nrRRAs=i_rrd_data.getNrRRAs()
        var rra_idx=0;
            //This is wrong I think...
        var ds_list=[];
        var ds = i_rrd_data.getDS('traffic_rx');
        ds_list.push(ds);
        var ds = i_rrd_data.getDS('traffic_tx');
        ds_list.push(ds);
        var flot_obj=rrdRRA2FlotObj(i_rrd_data, rra_idx, ds_list, true, true);
        $.plot("#placeholder", flot_obj);
    }
    

    Maybe someone can help?

    Regards
    Floh1111

     
  • Igor Sfiligoi

    Igor Sfiligoi - 2011-06-07

    Hi Floh.

    Indeed currently there is no way to specify the size of the graph.
    We will add it to the next version.

    Thanks for the input,
      Igor

     
  • Floh1111

    Floh1111 - 2011-06-07

    Okay thats not such a big problem because I have already seen the location where the size can be changed in the class directly. But is there a way to draw a plain graph without the timeline and the other stuff?

    Regards
    Clemens

     
  • Igor Sfiligoi

    Igor Sfiligoi - 2011-06-07

    RRDFlot uses just Flot for plotting.
    So you can do whatever Flot allows you to:
    http://code.google.com/p/flot/

    Personally, I never tried to disable the timeline, but it may be possible.

    Igor

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.