The Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by NCTM or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Grouping Legend Entries Together
Replies: 0  

Advanced Search

Back to Topic List Back to Topic List  
Tyler Herrington

Posts: 1
From: Vancouver, Canada
Registered: 5/5/13
Grouping Legend Entries Together
Posted: May 5, 2013 2:41 PM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply


I am plotting Arctic Sea Ice area against cumulative emissions, and have 24 curves (model runs) from 5 (five) cumulative emissions groups (1000, 2000, 3000, 4000, and 5000 GtC). What I want to do is group all the runs together which are from the same cumulative emissions group (which I've done by specifying the same colour for runs from a particular cumulative emissions group). Thus it would be best to have one legend entry for each cumulative emissions group (rather than a legend entry for each run!).

My current plot structure (minus the legend script) is as follows:


xlabel('Cumulative Emissions (GtC)')
ylabel('Northern Hemisphere Sea Ice Area (m ^2)')
title('Average September NH Sea Ice Area (2000-2500) for the 1000-5000 GtC scenarios')

SVBar, SVBar2, ..., SVBar24 are the sea ice area curves, and CumEmFAST1000SVV, CumEmVFAST1000SVV, ..., CumEmPULSE5000SVV refer to the corresponding cumulative emission values.

My idea is to have the following items grouped together within the legend, using the following legend entries (1000 GtC, 2000 GtC, 3000 GtC, 4000 GtC, 5000 GtC):

1000 GtC: SVBar, CumEmFAST1000SVV SVBar2, CumEmVFAST1000SVV SVBar4, CumEmOVST1000SVV SVBar5, CumEmPULSE1000SVV

2000 GtC: SVBar6, CumEmFAST2000SVV SVBar7, CumEmMEDIUM2000SVV SVBar8, CumEmSLOW2000SVV SVBar9, CumEmOVST2000SVV SVBar10, CumEmPULSE2000SVV

3000 GtC: SVBar11, CumEmFAST2000SVV SVBar12, CumEmMEDIUM2000SVV SVBar13, CumEmSLOW2000SVV SVBar14, CumEmOVST2000SVV SVBar15, CumEmPULSE2000SVV

4000 GtC: SVBar16, CumEmFAST4000SVV SVBar17, CumEmMEDIUM4000SVV SVBar18, CumEmSLOW4000SVV SVBar19, CumEmOVST4000SVV SVBar20, CumEmPULSE4000SVV

5000 GtC: SVBar21, CumEmFAST5000SVV SVBar22, CumEmMEDIUM5000SVV SVBar23, CumEmSLOW5000SVV SVBar24, CumEmOVST5000SVV SVBar25, CumEmPULSE5000SVV

I am not certain, however, how to set up my legend script to group the legend entries together?

Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum at NCTM 1994-2017. All Rights Reserved.