<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=ISO-8859-1">
</head>
<body bgcolor="#FFFFFF" text="#000000">
Dear all<br>
I've built two ref groups (ref1.csv, ref2.csv) and genind objects
(x1, x2) as following, now when I am trying to simulate
hybridization with these two the error coming as appended at last;
moreover in '@tab:' it showing different size matrix for x1 and x2
(20 X 32 for x1 and 20 X50 for x2) whereas both having 20
individuals, six loci and four alleles (per locus) each (sorry not
in the script here)<br>
<br>
Can anyone suggest me what is going wrong in it....<br>
Thanks<br>
( attaching ref1 and ref2)<br>
<br>
......<br>
> obj1<-read.table("ref1.csv")<br>
> obj1<br>
...<br>
.....<br>
> dat1<-data.frame(obj1, sep=",", ploidy=4)<br>
> dat1<br>
....<br>
> dat1<-data.frame(obj1)<br>
> dat1<br>
.....<br>
> x1=df2genind(dat1, sep=",", ploidy=4)<br>
> x1<br>
<br>
#####################<br>
### Genind object ### <br>
#####################<br>
- genotypes of individuals - <br>
<br>
S4 class: genind<br>
@call: df2genind(X = dat1, sep = ",", ploidy = 4)<br>
<br>
@tab: 20 x 32 matrix of genotypes<br>
<br>
@ind.names: vector of 20 individual names<br>
@loc.names: vector of 6 locus names<br>
@loc.nall: number of alleles per locus<br>
@loc.fac: locus factor for the 32 columns of @tab<br>
@all.names: list of 6 components yielding allele names for each
locus<br>
@ploidy: 4<br>
@type: codom<br>
<br>
Optionnal contents: <br>
@pop: - empty -<br>
@pop.names: - empty -<br>
<br>
@other: - empty -<br>
<br>
> hybridize(x1, x2, 40, pop=NULL, res.type=c("genind"),file=NULL,
quiet=FALSE, sep=",", hyb.label="h")<br>
<br>
<b>Error in Ops.data.frame(tab1, tab2) : <br>
+ only defined for equally-sized data frames<br>
In addition: Warning messages:<br>
1: In if (<a class="moz-txt-link-abbreviated" href="mailto:x@loc.nall">x@loc.nall</a> == 1) tabfreq <- t(tabfreq) :<br>
the condition has length > 1 and only the first element will
be used<br>
2: In if (<a class="moz-txt-link-abbreviated" href="mailto:x@loc.nall">x@loc.nall</a> == 1) tabfreq <- t(tabfreq) :<br>
the condition has length > 1 and only the first element will
be used<br>
<br>
<br>
</b>
<pre class="moz-signature" cols="72">--
AVIK RAY
Visiting Fellow
National Center for Biological Sciences
Tata Institute of Fundamental Research
GKVK Campus
Bellary Road
Bangalore-560065
India
Ph 91-80-23666340
Fax 91-80-2363 6662
</pre>
</body>
</html>