Transport Tycoon Forums

The place to talk about Transport Tycoon
It is currently Tue Mar 19, 2019 5:08 am

All times are UTC




Post new topic  Reply to topic  [ 64 posts ]  Go to page 1 2 3 4 Next
Author Message
 Post subject: Patch: New graphs
PostPosted: Tue May 15, 2007 10:49 am 
Offline
Engineer
Engineer
User avatar

Joined: Fri Apr 27, 2007 5:58 pm
Posts: 97
Location: Vegas baby
Here is what I have so far. I modified a cool idea from this post for the cargo payment graph.

Latest diff availiable here.

Differences from trunk:
Black background
Sizeable, sticky graph windows
25 year history
Smooth, Growth and % change* options.
Cargo payment graph based on speed and distance
Speed easily adjustable
Cargo legend same as player legend.
Cargo sorted by initial value.

*% change currently sucks.


Attachments:
cargo payments.png
cargo payments.png [ 23.57 KiB | Viewed 26282 times ]
new graphs r9872.diff [58.89 KiB]
Downloaded 605 times
company growth smooth.png
company growth smooth.png [ 15.11 KiB | Viewed 26254 times ]

_________________
I'm on the Zoloft to keep me from killing yall

My patches: Better graphs - Train acceleration - Crash rates


Last edited by Zojj on Sun Jul 15, 2007 8:23 am, edited 12 times in total.
Top
   
 Post subject:
PostPosted: Tue May 15, 2007 10:51 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Sat Apr 24, 2004 10:43 am
Posts: 2007
Location: Venezia - Italia
diff, please ;)

(good work, indeed)

_________________
ImageImage
ImageImage
ImageImage
newgrf tests, see: newgrf test topic, my patches: Wolf01's Hire Point
Italian TTD Forum
Wiki Page


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 11:02 am 
Offline
Engineer
Engineer
User avatar

Joined: Fri Apr 27, 2007 5:58 pm
Posts: 97
Location: Vegas baby
It is only half done. Diff in a day or 3. =)

_________________
I'm on the Zoloft to keep me from killing yall

My patches: Better graphs - Train acceleration - Crash rates


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 11:17 am 
Offline
OpenTTD Developer
OpenTTD Developer

Joined: Thu Feb 09, 2006 7:15 pm
Posts: 3815
What about black-on-black as used in the graph with cargos.


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 11:33 am 
Offline
Route Supervisor
Route Supervisor

Joined: Mon Apr 02, 2007 8:13 pm
Posts: 399
Location: Nørup, Denmark
very nice :)

_________________
Code:
if (YouAreHappyAndYouKnowIt) {
    ClapYourHands();
}


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 11:34 am 
Offline
Route Supervisor
Route Supervisor
User avatar

Joined: Tue Apr 26, 2005 7:06 pm
Posts: 435
Location: Sweden
Damn, I love you know. I always found the old graphs being too restrictive, same for the old budget window. I hope it will be possible to have data over the like, last 100 years too. :)


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 11:47 am 
Offline
Tycoon
Tycoon
User avatar

Joined: Mon May 02, 2005 11:05 am
Posts: 15415
Skype: XeryusTC
Location: localhost
I don't like the black background too much, I think staying with the old gray would be way better.

_________________
Don't panic - My YouTube channel - Follow me on twitter (@XeryusTC) - Play Tribes: Ascend - Tired of Dropbox? Try SpiderOak (use this link and we both get 1GB extra space)
Image
OpenTTD: manual #openttdcoop: blog | wiki | public server | NewGRF pack | DevZone
Image Image Image Image Image Image Image


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 12:23 pm 
Offline
Transport Coordinator
Transport Coordinator

Joined: Mon Feb 06, 2006 11:58 pm
Posts: 340
I think it is way easier to read the graph with black background.
Yes, it looks different somehow.
But over time we will get used to it.

_________________
Copy & Paste Patch for OTTD
Distant-Joined Stations Patch for OTTD
Eyecandy Patch for OTTD


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 12:49 pm 
Offline
Director
Director

Joined: Tue Jan 03, 2006 8:45 pm
Posts: 560
Location: Netherlands
Just a little suggestion...
Would it be possible to show a graph with the growth (in percent) of the profit, income, and/or the company value*? It would also be nice to have the level of inflation shown in such a graph.
I would even suggest that growth of income or company value (minus inflation) should become an entry of the performance rating.


*In separate graphs, of course.


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 4:42 pm 
Offline
Tycoon
Tycoon
User avatar

Joined: Tue Dec 10, 2002 8:36 pm
Posts: 7571
Skype: Bornacorn
Location: Wrexham, Wales
Ooh, I like the black background, much more stylish than the dark grey.

_________________
Image
FacebookFlickr PhotosBlogTwitterHosting


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 5:04 pm 
Offline
Traffic Manager
Traffic Manager

Joined: Sat Jun 05, 2004 12:22 pm
Posts: 173
I also love the black background! makes it much easier to read, imo. theres only one suggestion: maybe make the "year seperator lines" a bit more visible, I didnt notice they were there until I looked closely


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 5:17 pm 
Offline
Engineer
Engineer
User avatar

Joined: Fri Apr 27, 2007 5:58 pm
Posts: 97
Location: Vegas baby
Thanks all for feedback.

Rubidium wrote:
What about black-on-black as used in the graph with cargos.

Good thought. I'll make black cargo dark gray in the graph. Or something.

Ailure wrote:
I hope it will be possible to have data over the like, last 100 years too.

I have it saving 25 years now. Would need a scrollbar for more... hmm.

XeryusTC wrote:
I don't like the black background too much

Born Acorn wrote:
Ooh, I like the black background

This will be probably be a patch option. =)

hertogjan wrote:
...graph with the growth (in percent)...

Good idea, I'll see.

_________________
I'm on the Zoloft to keep me from killing yall

My patches: Better graphs - Train acceleration - Crash rates


Top
   
 Post subject:
PostPosted: Tue May 15, 2007 5:34 pm 
Offline
Traffic Manager
Traffic Manager

Joined: Fri Apr 13, 2007 5:07 pm
Posts: 156
You could add some options to select background colors, so everyone can get whatever he likes (pink with yellow hearts and blue flowers for example ;) ).


Top
   
 Post subject:
PostPosted: Wed May 16, 2007 11:26 pm 
Offline
Transport Coordinator
Transport Coordinator
User avatar

Joined: Tue Nov 09, 2004 10:33 pm
Posts: 357
Good job, this is a huge improvement!

_________________
NB: the below challenges are still open for submission, so feel free to perform necromancy on them!
Try the PouncingAnt National Monopoly Challenge
Or even better, the PouncingAnt National Monopoly Challenge 2
Or better still, the PouncingAnt National Monopoly Challenge 3
Or, the PouncingAnt National Monopoly Challenge 4

Or try my scenario instead!

-(A lazy) OpenTTD Japanese Translator-
-(A lazy) PNGcodec user-
"You get what you pay for, so pay attention!"

Patches:
Company Station Stats


Top
   
 Post subject:
PostPosted: Thu May 17, 2007 1:08 am 
Offline
Engineer
Engineer
User avatar

Joined: Fri Apr 27, 2007 5:58 pm
Posts: 97
Location: Vegas baby
Regular graphs almost done. =)

I'm open to suggestions for the name of the Growth button. It works for all history graphs, and is not always 'growth'.

.diff soon.

_________________
I'm on the Zoloft to keep me from killing yall

My patches: Better graphs - Train acceleration - Crash rates


Last edited by Zojj on Sat May 19, 2007 7:27 am, edited 1 time in total.

Top
   
 Post subject:
PostPosted: Thu May 17, 2007 8:26 am 
Offline
Director
Director

Joined: Tue Jan 03, 2006 8:45 pm
Posts: 560
Location: Netherlands
Is the "Growth" in your patch being measured absolutely (i.e., equal to the difference of values of two consecutive moments, in pounds, euros, dollars, etc.) or relatively (i.e., equal to the absolute growth divided by the previous value, in percent)?
I would rather go for the second option (although it may be good to include both options). In a graph of relative growth it is also possible to show the inflation level, so that you can see whether your company value growth is higher than the inflation rate.
For profits, a relative graph can be a little bit tricky, since zero or negative profits are also possible. However, for quantities which are always positive, such as company value and income, this is not an issue (only division by zero needs to be ruled out).


Top
   
 Post subject:
PostPosted: Sat May 19, 2007 7:26 am 
Offline
Engineer
Engineer
User avatar

Joined: Fri Apr 27, 2007 5:58 pm
Posts: 97
Location: Vegas baby
Diff up! See 1st post. Smooth is smooth =)

hertogjan,
I added a percent change button per request, but the graph it creates is not interesting. It needs different constraints, and maybe a logarithmic scale... even then I don't know if it would be useful. Feel free to play with the percent code, maybe you can find something that works!


Attachments:
delivered normal.png
delivered normal.png [ 10.89 KiB | Viewed 26285 times ]
delivered smooth.png
delivered smooth.png [ 9.56 KiB | Viewed 26262 times ]

_________________
I'm on the Zoloft to keep me from killing yall

My patches: Better graphs - Train acceleration - Crash rates
Top
   
 Post subject:
PostPosted: Sat May 19, 2007 10:29 am 
Offline
Route Supervisor
Route Supervisor

Joined: Mon Apr 02, 2007 8:13 pm
Posts: 399
Location: Nørup, Denmark
That looks so sweet!

Really nice work :)

_________________
Code:
if (YouAreHappyAndYouKnowIt) {
    ClapYourHands();
}


Top
   
 Post subject:
PostPosted: Sun May 20, 2007 8:35 pm 
Offline
Director
Director

Joined: Tue Jan 03, 2006 8:45 pm
Posts: 560
Location: Netherlands
About the smoothing function, what exactly does it do? Is it true that if you enable it, then the graph doesn't show the actual values? If so, I find that confusing. I would rather go for showing the actual data points, but a smoothed line. Then the points generally do not lie on the graph, but may be below or above it.*
As for the growth percentage, the patch is computing the growth relative to the last quarter (if I'm not mistaken). In my opinion, the growth relative to the same quarter of the previous year is more interesting.
For the quantities that can take negative values (e.g. operating profit), it is better to show nothing (i.e., growth is undefined) if either the current point or the previous point (or both) has a negative value.
I did not read the code very thoroughly, so I don't know what you have done so far to eliminate large growth percantages if the value of the previous data point is low, but it may be necessary to limit the values shown on the graph to, say, 1000%.

I hope these suggestions are useful.


*If you don't understand it at this point, ask me for a picture to explain it.


Top
   
 Post subject:
PostPosted: Sun May 20, 2007 8:53 pm 
Offline
Transport Coordinator
Transport Coordinator

Joined: Wed Apr 14, 2004 3:18 pm
Posts: 312
Location: Fr
@hertogjan

I really like the smooth that Zojj did, let me explain you.
see the green "normal" lines...
from year 2025 to 2031, you see the draw has two values : 190 and 380.
it's like your train just performed one or two trip during the quarter (long trip).
does it mean something ? does 2025Q2 had twice activity of 2025Q3 ? (no, in fact your train was on road)
does it mean your trains was broken ? no..
the flow was the same, it's just the trip are very long.

finaly look at the smooth graph, it's closer than reality : average value of 280.
these value are not wrong, it just than quarter value are too tight.
Imagine daily values : you will have just zero every where and from time to time some high value...

and if really you prefer raw value, don't use the smooth button ;)

@zojj : please keep it like this ;)


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 64 posts ]  Go to page 1 2 3 4 Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 2 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB © 2000-2019 phpBB Limited

Copyright © Owen Rudge/The Transport Tycoon Forums 2001-2019.
Hosted by Zernebok Hosting.