forums.silverfrost.com Forum Index forums.silverfrost.com
Welcome to the Silverfrost forums
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Dynamic Simpleplot

 
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Suggestions
View previous topic :: View next topic  
Author Message
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Sat Mar 09, 2013 1:19 am    Post subject: Dynamic Simpleplot Reply with quote

Would be nice and logical to extend a bit functionality of Simpleplot by allowing some dynamic run-time changes the same way and style as it is typically done in CWP by using @ -- in this case by %pl@ instead of fixed parameters %pl[parameters] :

Code:


  text256 = 'x_axis="Width [rel.un.]",y_axis="Intensity [rel.un.]",&
  &title="Intg (black),  Inst (red)",colour=red,&
  & X_ARRAY, LOG_LOG, N_GRAPHS=2'

  i=winio@('%pv%pl@&', text256, 500, 300, npoints, Xarray, Yarray, Yinterp )



This would allow to set Y minimum and maximum, change LOG and LIN axis scales, change titles and axis names etc:

Another improvement would be allowing multiple plots with their own sets of (X,Y) pairs. Right now for multiplots Simpleplot allows just one common X set for multiple Y ones.
Back to top
View user's profile Send private message
PaulLaidler
Site Admin


Joined: 21 Feb 2005
Posts: 7916
Location: Salford, UK

PostPosted: Sat Mar 09, 2013 7:54 am    Post subject: Reply with quote

Thanks for this.
Back to top
View user's profile Send private message AIM Address
DanRRight



Joined: 10 Mar 2008
Posts: 2813
Location: South Pole, Antarctica

PostPosted: Sat Mar 09, 2013 1:01 pm    Post subject: Reply with quote

And by Simpleplot i always meant just the %pl, the clever idea general Fortran is missing, I never used the whole Simpleplot subroutines package which seems is not supported anymore by the author ( I may try it if its library is free now to find if something is useful and not too obsolete there). Rebuilding just the %pl if Silferfrost will decide so would be not that difficult, just follow 2-3 best ever looking (with WOW factor) most common 2D and 3D examples (for which use OpenGL) and forget about anything else which may bury you for years and decades into heavy programming.

(May be the best ever strategy for best graphics would be to link CWP not to libraries but to professional graphics **editing** packages like Origin, Techplot...The idea is to edit the graph in, say, Origin and then make its setup callable from CWP. If you have many graphs in your programs - they all will have their own Origin setup. Then if you will need some adjustments, for example change the font or Y limit, - all must be done within Origin, the Fortran code with CWP just supply data and arrange the window size and position where graph will appear. That way graphics within Fortran will never be obsolete and will not need support. Such type of graphics packages usually do not go out of business quick because of their often use in presentations everyone now do unlike all callable libraries only few programmers use)
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    forums.silverfrost.com Forum Index -> Suggestions All times are GMT + 1 Hour
Page 1 of 1

 
Jump to:  
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 vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group