Patch: New graphs
Moderator: OpenTTD Developers
feature request
Could the scales of both axes be adapted to 'beautiful' values?
E.g. if your scale runs from 0 to 1024, it is normal to create 22 gridlines: 0, 50, 100, ...., 1000, 1050. On a small graph one might use 12 gridlines: 0, 100, 200, ... , 1000, 1100.
Algorithms for this are in existence, and it would enhance the readability of the graphs greatly.
E.g. if your scale runs from 0 to 1024, it is normal to create 22 gridlines: 0, 50, 100, ...., 1000, 1050. On a small graph one might use 12 gridlines: 0, 100, 200, ... , 1000, 1100.
Algorithms for this are in existence, and it would enhance the readability of the graphs greatly.
A game worth playing is a game worth modding 

Re: feature request
Cool! No problem. I hope people find your build useful.chrissicom wrote:What I did was only changing the graph from days in transit to seconds in transit since that is not a relative value affected by the daylength patch.
Good thought. I was lazy and kept the horiz grid spacing the same as TTD. If I change the graph it to use rounder increments (50,100,1000...), I think the horiz. grid spacing would need to vary... hmmgriffin71 wrote:Could the scales of both axes be adapted to 'beautiful' values?
I'm on the Zoloft to keep me from killing yall
My patches: Better graphs - Train acceleration - Crash rates
My patches: Better graphs - Train acceleration - Crash rates
Re: Patch: New graphs
I'm considering continuing work on this patch.. mostly depends if it has a chance of being included in the trunk.
I plan on doing this:
1. Update to current trunk
2. Gray background option in the patch settings (normal, better with black bg, better with gray bg)
3. Rounded numbers on the Y-axis
4. Update coding style as required. Feedback from devs appreciated.
Post your thoughts or requests please!
I plan on doing this:
1. Update to current trunk
2. Gray background option in the patch settings (normal, better with black bg, better with gray bg)
3. Rounded numbers on the Y-axis
4. Update coding style as required. Feedback from devs appreciated.
Post your thoughts or requests please!
I'm on the Zoloft to keep me from killing yall
My patches: Better graphs - Train acceleration - Crash rates
My patches: Better graphs - Train acceleration - Crash rates
Re: Patch: New graphs
the more graphs the better!
especially in multiplayer it is nice to compare your company with others! And if somebody doesnt like them, then he just dont have to use them 
- one suggestion - maybe adding some cool eycandy - ie splines for connecting "dots" or "values" instead of current lines. This will make graphs much smoother. And also some kind of floating average.


- one suggestion - maybe adding some cool eycandy - ie splines for connecting "dots" or "values" instead of current lines. This will make graphs much smoother. And also some kind of floating average.
Re: Patch: New graphs
Smoother, but IMHO maybe inaccurate, as you never know what happens "between the points" and for values like 100,700,700,100 you may get some false peak between the two 700's with value perhaps like 800. Also, somebody will need to add support for splines to openttd (they are a bit more difficult than drawing simple lines, especially if you want some clipping and good drawing speed - although not so hard to implement, it still may be quite some work ...)Volny wrote:the more graphs the better! :) especially in multiplayer it is nice to compare your company with others! And if somebody doesnt like them, then he just dont have to use them :)
- one suggestion - maybe adding some cool eycandy - ie splines for connecting "dots" or "values" instead of current lines. This will make graphs much smoother. And also some kind of floating average.
I don't think splines in these graphs are a good idea.
If you need something, do it yourself or it will be never done.
My patches: Extra large maps (1048576 high, 1048576 wide) (FS#1059), Vehicle + Town + Industry console commands (FS#1060), few minor patches (FS#2820, FS#1521, FS#2837, FS#2843), AI debugging facility
Other: Very large ships NewGRF, Bilbo's multiplayer patch pack v5 (for OpenTTD 0.7.3)
My patches: Extra large maps (1048576 high, 1048576 wide) (FS#1059), Vehicle + Town + Industry console commands (FS#1060), few minor patches (FS#2820, FS#1521, FS#2837, FS#2843), AI debugging facility
Other: Very large ships NewGRF, Bilbo's multiplayer patch pack v5 (for OpenTTD 0.7.3)
Re: Patch: New graphs
True. If the point values are kept the same, then with a smooth curve the area (cumulative total) will be incorrect. I could keep the area the same and adjust the points... that would be better, but still inaccurate. I would use parabolic curves.Bilbo wrote: for values like 100,700,700,100 you may get some false peak between the two 700's
But not yet... I'm still waiting for someone to say this patch has a good chance of inclusion.

I'm on the Zoloft to keep me from killing yall
My patches: Better graphs - Train acceleration - Crash rates
My patches: Better graphs - Train acceleration - Crash rates
- orudge
- Administrator
- Posts: 25214
- Joined: 26 Jan 2001 20:18
- Skype: orudge
- Location: Banchory, UK
- Contact:
Re: Patch: New graphs
Just to give my opinion on these graphs - I think they look rather good. Hopefully if the code is up to scratch they can be submitted to the repository. 

- belugas
- OpenTTD Developer
- Posts: 1507
- Joined: 05 Apr 2005 01:48
- Location: Deep down the deepest blue
- Contact:
Re: Patch: New graphs
for the record, I second orudge
If you are not ready to work a bit for your ideas, it means they don't count much for you.
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
OpenTTD and Realism? Well... Here are a few thoughs on the matter.
He he he he
------------------------------------------------------------
Music from the Bloody Time Zones
Re: Patch: New graphs
I haven't looked at your patch until now, and i haven't got a voice that counts in terms of trunk inclusion, but i just have to second all the others that find your graphs very useful. Also the "smooth" option is very promising if you want a bigger picture about what is happening, where all the spikes are just distracting.
I know that my trains sometimes manage to do two deliveries in a year, sometimes one. That's not the info I'm looking for in the graph
So, great patch and hopefully a candidate for inclusion as orudge and belugas are saying...
I know that my trains sometimes manage to do two deliveries in a year, sometimes one. That's not the info I'm looking for in the graph

So, great patch and hopefully a candidate for inclusion as orudge and belugas are saying...
Re: Patch: New graphs
Yay! Motivation 

I'm on the Zoloft to keep me from killing yall
My patches: Better graphs - Train acceleration - Crash rates
My patches: Better graphs - Train acceleration - Crash rates
Re: Patch: New graphs
I love this patch, but it seems like it has not been maintained which is a real shame
player.h doesn't even exist anymore and so the current patch doesn't work at all for the latest SVN trunk. Anyone feel like updating it for the latest trunk? I might have to see if I can if nobody else will/has, because I like these graphs so much. 


=== Jez ===
Re: Patch: New graphs
@zojj: Will there ever be a new version of this patch? I'd really love to see a new version
@chrissicom: You use this patch in your latest ChrisIN. Do you have a newer version than the one on this thread?
@chrissicom: You use this patch in your latest ChrisIN. Do you have a newer version than the one on this thread?
Re: Patch: New graphs
There's hope. I got it up and running now. Still crashes when i click on key, the cargo payment rates dont work and the cargo graph legend doesn't seem to like ECS very much, but other than that it works
Edit: Cargo payment rates work, just not with ECS.
Edit: Cargo payment rates work, just not with ECS.
- Attachments
-
- Gordon & Co., 18th Oct 1981.png
- Screenshot is even in english.
- (300.06 KiB) Downloaded 169 times
Re: Patch: New graphs
And here it is. Works with latest trunk (12733).
- Attachments
-
- bettergraphs_r12714.patch
- (51.25 KiB) Downloaded 183 times
-
- Bigwig & Co., 17th Apr 1952.png
- (103.85 KiB) Downloaded 174 times
Re: Patch: New graphs
Awesome! Thanks for updating my patch. I don't have time anymore =(
I'm on the Zoloft to keep me from killing yall
My patches: Better graphs - Train acceleration - Crash rates
My patches: Better graphs - Train acceleration - Crash rates
Re: Patch: New graphs
I've noticed Roest's update of this patch makes an unneeded modification to variables.h. Its just something that can be cleaned up the next time it is updated.
Re: Patch: New graphs
Hmm? It's probably been there before i meddled with it.
Re: Patch: New graphs
update, should work with newindustries now,
please report any bugs you find
please report any bugs you find
- Attachments
-
- bettergraphs_r12837.patch
- (50.6 KiB) Downloaded 183 times
-
- Unnamed, 20th Mar 1950.png
- (129.32 KiB) Downloaded 189 times
Re: Patch: New graphs
Hmm. I've got a suggestion: The growth views could do with an own vertical scaling. If absolute values are high and changes small, the growth graph is practically unreadable.
Very useful patch, though..
Very useful patch, though..
Re: Patch: New graphs
updated to r13117
That issue is known, but don't have time to fix it right now.AndiK wrote:Hmm. I've got a suggestion: The growth views could do with an own vertical scaling. If absolute values are high and changes small, the growth graph is practically unreadable.
Very useful patch, though..
- Attachments
-
- bettergraphs_r13117.patch
- (49.07 KiB) Downloaded 179 times
Who is online
Users browsing this forum: No registered users and 4 guests