Support » Fixing WordPress » [Plugin: Tally Graph] Having some issues

  • This looks like a great plugin, but I seem to be having some issues. I sent you an email, but perhaps I should have posted here.

    I think I’ve been able to slowly work out most of it, except for the fact that when ever I set the interval to week, it completely breaks the graph.

    View here:

    The first one is set to day with this code:

    [tally_graph key=”Weight” tally_interval=”day” cht=”lc” chs=”540×200″]

    Second is set to week with this:

    [tally_graph key=”Weight” tally_interval=”week” cht=”lc” chs=”540×200″]

    If I could get that working… Then I’m just wondering if theres a way to keep it from shooting down to zero when ever there isnt an entry. It sounds to me like the ‘delta’ method is for this, but when I add it to the graph (3d example on that page, set to day) nothing seems to change. However, if I add a interval_count, which I will need, then it does have an effect. Just, not a good one… Heres the code for the 4th example:

    [tally_graph key=”Weight” tally_interval=”day” cht=”lc” chs=”540×200″ method=”delta”]

    And for what its worth, so far I’m just trying to create a weight graph/log.

    Any help is greatly appreciated, thanks

Viewing 5 replies - 1 through 5 (of 5 total)
  • Hi Chase,

    It looks to me like you do want to use the delta method. The documentation for that says:

    The delta method computes a running total, adding changes to the total for each interval. This can be used for data like weight loss and gain, where an initial entry is made with a starting weight, then gains and losses are recorded as positive and negative values.

    I think if you change your field values to do that, you’ll get the result you’re looking for.

    It does look like you may have found a bug with the weekly tally – probably it comes from difficulty with week numbering at the beginning of the year. Try it with some different interval counts, perhaps. We can work on that if it continues to be troublesome.

    Thanks for the response.

    I created some more posts set to August of 2008. The first is Aug 4th, then the 12th, and the 20th. All have custom fields with data, and I put the graph on the 20th. First I tried no interval count (incase it was just the new year) then tried 3, 6, and 11.. Still the same result. No data displaying, and its doubling the x axis numbers. Its also forcing me to designate a graph type.

    [tally_graph key=”Weight” cht=”lc” tally_interval=”week” interval_count=”11″ chs=”540×200″]

    On another note, I found a pretty nice site that allows you to set up a graph, choose your colors etc. and gives you the code. You still have to add the tally parameters, but its a quick way to add some color.

    And last, it looks like the delta method (at least in my case) is just continuously adding, even if the newer data is less than the previous. If I have one entry at 150, and the second is 100, the second graph will rise up to 250. So it looks like I’ll have to stick with the default.

    Anyway, despite the fact that I’m having some trouble, I can tell this is a great plugin with even greater potential. There really isnt anything else out there close to the concept for WP. Hopefully I’ll be able to get it working.

    Thanks for your efforts and help

    Hey Chase,

    Thanks for the link, I’m sure that will come in handy for myself and others.

    So if you want to use the delta method, you’ll have to record your weight gain or loss instead of your current weight. I suppose I could make a method that treats each point as a new total, I just didn’t think to do it that way.

    The underlying trouble here is that the API will not treat the X axis as a timeline and plot data points for you. Or it will, but the points are always equally spaced, with no sense of the actual time between them. That’s why tally graphs always have some fixed number of time intervals, so the time scale isn’t lost.

    Let’s start a separate thread for the week interval problem so I can track that as a bug. I’ll start it.

    That would be great if you could create a method that does that. That’d be awesome…

    Thats fine if there has to be fixed intervals and everything. I dont necessarily want it to ignore days that I dont post. Actually, I’d prefer if it didnt, if possible. Just average them out.

    Like if I only make 2 posts, first on day 1 at 50, and day 3 at 100, the graph would still show day 2, averaged out to 75.

    Or skip it, which ever is easier. That’d be great.

    I’ll try a few more things with the week interval. I have noticed that it seems to react different ways depending on the order of paramaters within the code. I’ll also try a reinstall of everything. Although I think your plugin was the first I installed on that test site, I’m pretty sure I used the automatic thing in the dashboard which has given me some trouble with other plugins, so I’ll do it manual next time. I’ll post my findings to the other thread.

    Again, thanks for all the help!

    I just released version 0.3 with a new ‘track’ method. It doesn’t do averaging, but it does fill in the gaps between entries.

Viewing 5 replies - 1 through 5 (of 5 total)
  • The topic ‘[Plugin: Tally Graph] Having some issues’ is closed to new replies.