5.0

5.0 | 1 rating Rate this file 135 downloads (last 30 days) File Size: 7.1 KB File ID: #24875

addaxes.m v1.1 (Sep 2009)

by Carlos Adrian Vargas Aguilera

 

29 Jul 2009 (Updated 21 Sep 2009)

Code covered by BSD License  

Adds a new linked axis related by ANY monotonic function. Includes ZOOM/PAN and DATETICK utility!

Download Now | Watch this File

File Information
Description

With PLOTYY you can add a new axis, which will be linearly related with the old one. With this function, the new axis may be related by ANY monotonic ascending or descending function with the old one (which should be specified), and works with the x-axis as well.

Besides, both axes will be linked to work with the ZOOM/PAN functionalities and even the DATETICK or TLABEL function for a time axis.

For example, to include a new x-axis with an exponential relationship with the old one just use:
>> addaxes('XFun','exp')

Enjoy it!
Any comments and bug reports will be very appreciated!

Acknowledgements

The author wishes to acknowledge the following in the creation of this submission:
addaxis, plots.m, plotses.m, tlabel.m v2.6.1 (Sep 2009), linkzoom.m v1.3 (Aug 2009)

MATLAB release MATLAB 7.7 (R2008b)
Other requirements It is recommended to download the TLABEL function as well.
Zip File Content  
Other Files addaxes.m,
license.txt
Tags for This File  
Everyone's Tags
Tags I've Applied
Add New Tags Please login to tag files.
Comments and Ratings (1)
02 Oct 2009 J. Caspar

Simply terrific. I've wanted something like this for years. Thank you!

Please login to add a comment or rating.
Updates
21 Sep 2009

v1.1 Fixed bug with function inversion, thanks to Allen Hall. Added 'Inverse' options and 'Position' link. Fixed small bug related with 'off' option.

Tag Activity for this File
Tag Applied By Date/Time
plotyy Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
linkaxes Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
datetick Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
tlabel Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
axes Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
pan Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
zoom Carlos Adrian Vargas Aguilera 30 Jul 2009 10:50:23
linkzoom Carlos Adrian Vargas Aguilera 21 Sep 2009 11:57:24
plotxx Carlos Adrian Vargas Aguilera 21 Sep 2009 11:57:24
 

MATLAB Central Terms of Use

NOTICE: Any content you submit to MATLAB Central, including personal information, is not subject to the protections which may be afforded information collected under other sections of The MathWorks, Inc. Web site. You are entirely responsible for all content that you upload, post, e-mail, transmit or otherwise make available via MATLAB Central. The MathWorks does not control the content posted by visitors to MATLAB Central and, does not guarantee the accuracy, integrity, or quality of such content. Under no circumstances will The MathWorks be liable in any way for any content not authored by The MathWorks, or any loss or damage of any kind incurred as a result of the use of any content posted, e-mailed, transmitted or otherwise made available via MATLAB Central. Read the complete Terms prior to use.

Contact us at files@mathworks.com