s-news
[Top] [All Lists]

Re: non-square persp plot?

To: Volker Bahn <lochapoka@web.de>
Subject: Re: non-square persp plot?
From: Prof Brian Ripley <ripley@stats.ox.ac.uk>
Date: Mon, 13 Dec 2004 15:00:30 +0000 (GMT)
Cc: s-news@wubios.wustl.edu
In-reply-to: <019c01c4e123$87a0bde0$c8a66f82@Context>
References: <019c01c4e123$87a0bde0$c8a66f82@Context>
I believe you can fill the *rectangle* with NAs if you want to exclude part of the surface. From ?persp

  Missing values (NAs) are allowed, but should generally not occur in the
  convex hull of the non-missing values.


On Mon, 13 Dec 2004, Volker Bahn wrote:

Dear list members,

I want to create a 3D persp plot that does not cover a square. Is that
possible? I calculated predictions from a model for certain parameter
combinations of R (growth rate) and death (death rate). However, certain
parameter combinations do not lead to results in the model so that I cannot
fill a square matrix with parameter combinations. The death rate cannot be
higher than the growth rate leading to a diagonal cut off in the possible
combinations. When I create a persp() plot from this, I get non-sense
extrapolations into the empty parameter space. Is it possible to turn this
off or cut it off? I searched help files and s-news archives but found
nothing. The data is posted below (Istd is the model output).

Thank you

Volker

R <- c(1.2, 1.4, 1.6, 1.8, 2, 1.4, 1.6, 1.8, 2, 1.4, 1.6, 1.8, 2, 1.6, 1.8,
2, 1.6, 1.8, 2, 1.8, 2)

death <- c(0.1, 0.1, 0.1, 0.1, 0.1, 0.2, 0.2, 0.2, 0.2, 0.3, 0.3, 0.3, 0.3,
0.4, 0.4, 0.4, 0.5, 0.5, 0.5, 0.6, 0.6)

Istd <- c(0.3973568, 0.3343699, 0.3183619, 0.3110495, 0.3068442, 0.3516840,
0.3234086, 0.3129532, 0.3074797, 0.3960007, 0.3324119, 0.3162299, 0.3088287,
0.3501716, 0.3216496, 0.3110916, 0.3950060, 0.3309720, 0.3146608, 0.3490352,
0.3203271)

--
Brian D. Ripley,                  ripley@stats.ox.ac.uk
Professor of Applied Statistics,  http://www.stats.ox.ac.uk/~ripley/
University of Oxford,             Tel:  +44 1865 272861 (self)
1 South Parks Road,                     +44 1865 272866 (PA)
Oxford OX1 3TG, UK                Fax:  +44 1865 272595

<Prev in Thread] Current Thread [Next in Thread>