<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
  <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type">
</head>
<body bgcolor="#ffffff" text="#000000">
<font face="Times New Roman, Times, serif">Dear Dirk,<br>
<br>
Please use the latest version of BIOMOD and R. <br>
<br>
I run the example from ?Models with 2 runs of PA. I did not get the
same dimensions between Sp.Env and the predictions using PA<br>
<br>
&gt; load("pred/Pred_Sp290")<br>
&gt; dim(Pred_Sp290)<br>
[1] 1773&nbsp;&nbsp;&nbsp; 9&nbsp;&nbsp;&nbsp; 3&nbsp;&nbsp;&nbsp; 1<br>
&gt; dim(Sp.Env)<br>
[1] 2264&nbsp;&nbsp; 18<br>
<br>
As you spotted this is obviously logical (1000 absences + 773
presences). Perhaps you have run an example without pseudo-absence
(NbRepPA=0). In that case, your absences are true absences, you do not
need to use the PA selection. Then, the predictions will be done on the
overall data. The predictions will have the same number of rows than
the initial data. <br>
<br>
However, you can still use the "level.plot" function even in the case
of pseudo-absence selection. <br>
If you type "ls", you should see that a list called "Biomod.PA.sample"
is present in your RData. This list contains the samples (row indices)
which have been used for each run for each species. <br>
<br>
For instance, if you want the rows used for the first species and the
first PA run: </font><font face="Times New Roman, Times, serif">Biomod.PA.sample$Sp290$PA1</font><br>
<font face="Times New Roman, Times, serif"><br>
In the BIOMOD example that I run, I used the following. It works well.<br>
<br>
level.plot(Pred_Sp290[,"GLM",2,1], CoorXY[Biomod.PA.sample$Sp290$PA1,]
, show.scale=FALSE, title="probabilities by GLM")<br>
<br>
In your example, try this the following. It should work. <br>
<br>
level.plot(Pred_Species1[,"GLM",2,1],
coord_na[Biomod.PA.sample$Species1$PA1,], show.scale=FALSE,
title="probabilities by GLM")<br>
<br>
Finally concerning the fact that it is recommended to add the name of a
species when you model only one species. It is simply a matter of how R
names vector and matrix. When you pass one species (ex: Sp.Env[, 15] or
Sp.Env$Sp290) in the Initial.State function. R converts it as a vector
and remove the name. It is lost. Then, your output will not have the
name, abbreviation or code of the species modelled but probably a X or
V. In case you would like to re-run BIOMOD for another species, it will
do the same think, and the previous outputs will be overwritten. Giving
a name, even a fake one, ensure the outputs will not be overwritten if
you rerun another species with another name. <br>
When you modelled two species or more, you deal with matrices or
dataframes which do not have this problem of column name. <br>
<br>
<br>
Hope it helps,<br>
Wilfried<br>
<br>
<br>
<br>
</font><br>
Dirk Amsel a &eacute;crit&nbsp;:
<blockquote cite="mid:604065.28425.qm@web24712.mail.ird.yahoo.com"
 type="cite">
  <table border="0" cellpadding="0" cellspacing="0">
    <tbody>
      <tr>
        <td
 style="font-family: inherit; font-style: inherit; font-variant: inherit; font-weight: inherit; font-size: inherit; line-height: inherit; font-size-adjust: inherit; font-stretch: inherit;"
 valign="top">Dear Wilfried, hello all!<br>
        <br>
I have worked the examples from the Help files, such as ?Models and
?Projection, and they run without problems.<br>
        <br>
However, when I apply the very same commands to my data, something goes
wrong.<br>
        <br>
Essentially, after the call to Models(..., sp.name = "Species1") (btw,
why do I have to name a single species, when two unnamed species are
acceptable?), I have<br>
        <br>
&gt; load("pred/Pred_Species1")<br>
&gt; dim(Pred_Species1)<br>
[1] 2953&nbsp;&nbsp;&nbsp; 9&nbsp;&nbsp;&nbsp; 3&nbsp;&nbsp;&nbsp; 2<br>
&gt; dim(env_na) # env_na is my data matrix ("Sp.Env" in ?Models)<br>
[1] 176456&nbsp;&nbsp;&nbsp;&nbsp; 14<br>
&gt; # ?<br>
        <br>
where 2953 == 1953 + 1000 == number of presences + nb.absences.
Finally, level.plot complains about these different dimensions, 2953
vs. 176456. But in the example from ?Models, these dimension match.<br>
        <br>
What is going wrong -- any ideas?<br>
        <br>
        <br>
Best regards,<br>
        <br>
Dirk<br>
        <br>
        <br>
p.s. I have attached the full transcript of my R session<br>
        <br>
        </td>
      </tr>
    </tbody>
  </table>
  <br>
  <pre wrap=""><pre wrap="">
<hr size="4" width="90%">
_______________________________________________
Biomod-commits mailing list
<a class="moz-txt-link-abbreviated" href="mailto:Biomod-commits@lists.r-forge.r-project.org">Biomod-commits@lists.r-forge.r-project.org</a>
<a class="moz-txt-link-freetext" href="https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/biomod-commits">https://lists.r-forge.r-project.org/cgi-bin/mailman/listinfo/biomod-commits</a>
</pre></pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">-- 
--
Wilfried Thuiller
Laboratoire d'Ecologie Alpine, UMR-CNRS 5553
Universit&eacute; J. Fourier
BP 53, 38041 Grenoble Cedex 9, France
Tel: +33 (0)4 76 63 54 53
Fax: +33 (0)4 76 51 42 79

Email: <a class="moz-txt-link-abbreviated" href="mailto:wilfried.thuiller@ujf-grenoble.fr">wilfried.thuiller@ujf-grenoble.fr</a>
Home page: <a class="moz-txt-link-freetext" href="http://www.will.chez-alice.fr">http://www.will.chez-alice.fr</a>
Website: <a class="moz-txt-link-freetext" href="http://www-leca.ujf-grenoble.fr/equipes/tde.htm">http://www-leca.ujf-grenoble.fr/equipes/tde.htm</a>

FP6 European MACIS project: <a class="moz-txt-link-freetext" href="http://www.macis-project.net">http://www.macis-project.net</a>
FP6 European EcoChange project: <a class="moz-txt-link-freetext" href="http://www.ecochange-project.eu">http://www.ecochange-project.eu</a></pre>
</body>
</html>