Path: news.mathworks.com!not-for-mail
From: "Rick Rosson" <rrosson@mathworks.com>
Newsgroups: comp.soft-sys.matlab
Subject: Re: text in figures with subplots
Date: Tue, 31 Jul 2007 08:19:30 -0400
Organization: The MathWorks, Inc.
Lines: 43
Message-ID: <f8n9cj$red$1@fred.mathworks.com>
References: <f8n48j$poj$1@fred.mathworks.com> <f8n55i$bph$1@fred.mathworks.com>
Reply-To: "Rick Rosson" <rrosson@mathworks.com>
NNTP-Posting-Host: rossonr.dhcp.mathworks.com
X-Trace: fred.mathworks.com 1185884371 28109 144.212.206.185 (31 Jul 2007 12:19:31 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Tue, 31 Jul 2007 12:19:31 +0000 (UTC)
X-Priority: 3
X-MSMail-Priority: Normal
X-Newsreader: Microsoft Outlook Express 6.00.2900.3138
X-RFC2646: Format=Flowed; Original
X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.3138
Xref: news.mathworks.com comp.soft-sys.matlab:421842


A slightly modified version that provides additional
handles for greater control and flexibility:

   fig = figure;

   a(1) = subplot(2,2,1);
   p(1) = plot(rand(10,1));

   a(2) = subplot(2,2,2);
   p(2) = plot(rand(10,1));

   a(3) = subplot(2,2,3);
   p(3) = plot(rand(10,1));

   a(4) = subplot(2,2,4);
   p(4) = plot(rand(10,1));

   ax = axes('position',[0,0,1,1],'visible','off');
   tx = text(0.4,0.95,'This is the Header');
   set(tx,'fontweight','bold');






"us " <us@neurol.unizh.ch> wrote in message 
news:f8n55i$bph$1@fred.mathworks.com...
> Michel Slivitzky:
> <SNIP needs text far far away from his/her plots...
>
> one of the solutions
>
>     subplot(2,2,1);
>     plot(rand(10,1));
>     ah=gca;
>     axes('position',[0,0,1,1],'visible','off');
>     text(.5,.25,'test');
>     axes(ah);
>
> us