I couldn't read the yaml file

66 views
Skip to first unread message

李凯

unread,
Jan 15, 2021, 10:30:11 AM1/15/21
to R/qtl2 discussion

Dear Karl,

Sorry to bother you, but I met some troubles when trying to read the "yaml" file.

Here is my script for creating such control file:
***
write_control_file(
  fa_control_file,
  crosstype = "riself4",
  geno_file = "fa_geno.csv",
  founder_geno_file = "fa_foundergeno.csv",
  gmap_file = "fa_gmap.csv",
  pheno_file = "fa_pheno.csv",
  crossinfo_file = "fa_crossinfo.csv",
  geno_codes = c(A=1L, B=2L),
  alleles = c("A", "B"),
  sep = ",",
  na.strings = c("-", "NA"),
)
***

However, when running the function "read_cross2", there is always a warning:"No markers in common between map and genotypes." After checking twice and ensuring that they have the same names and orders in "geno", "gmap", "foundergeno" and "pmap" csv.

If you need my dataset for testing, I would send you as soon as possible.

Thank you very much!

Kai Li

Karl Broman

unread,
Jan 15, 2021, 10:31:06 AM1/15/21
to R/qtl2 discussion
I can't tell without looking at the data.

karl

Karl Broman

unread,
Jan 15, 2021, 10:31:52 AM1/15/21
to R/qtl2 discussion
Maybe the genotype data files are transposed so it's interpreting the individual IDs as marker names and vice versa?

karl

李凯

unread,
Jan 16, 2021, 1:13:34 PM1/16/21
to rqtl2...@googlegroups.com
Dear Karl, I am very sorry to bother you but this reading problem nearly drove me crazy.
Here attached is my experimental file, and both the genotype and map data are arranged as the example file "qtl2data/MaizeMAGIC". However, I still met the same problem.
Would you mind offering some solutions?
Thank you very much!

Kai Li

Karl Broman <kbr...@gmail.com> 于2021年1月15日周五 下午4:31写道:
--
You received this message because you are subscribed to the Google Groups "R/qtl2 discussion" group.
To unsubscribe from this group and stop receiving emails from it, send an email to rqtl2-disc+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rqtl2-disc/b65b7682-048b-4856-8c5a-c62eb445649fn%40googlegroups.com.
R_qtl2.zip

Karl Broman

unread,
Jan 16, 2021, 1:56:34 PM1/16/21
to R/qtl2 discussion
1. If you have markers as rows and individuals as columns, you need to include

geno_transposed: true
founder_geno_transposed: true

2. for the riself4 cross type, the genotypes need to be converted to 1,3, so in yaml file you should have

genotypes:
  A: 1
  B: 3

3. for "riself4", the alleles should have four values

alleles:
- A
- B
- C
- D

4. In the founder genotype file, there should be *four* founder strains, not just 3.

5. In the crossinfo file, you need ID followed by four columns indicate the order of the founders when making the cross as a permutation {1,2,3,4}, like:

NAM1,1,2,3,4
NAM2,1,3,2,4

In the attached, I made these adjustments.

karl
fa.zip

李凯

unread,
Jan 16, 2021, 1:58:16 PM1/16/21
to rqtl2...@googlegroups.com
Thank you very much! I would test it right now!

Karl Broman <kbr...@gmail.com> 于2021年1月16日周六 下午7:56写道:

李凯

unread,
Jan 16, 2021, 2:13:42 PM1/16/21
to rqtl2...@googlegroups.com
I am sorry but for the crossinfo: each offspring line is developed by crossing only two parents and selfing itself. Therefore, what I could write is something like this:
NAM1,1,2
NAM2,1,2
.
.
.
NAM50, 3, 4
But is it feasible to read such "crossinfo" file?


李凯 <likai2...@gmail.com> 于2021年1月16日周六 下午7:58写道:

Karl Broman

unread,
Jan 16, 2021, 2:24:55 PM1/16/21
to R/qtl2 discussion

No this won’t work.  The crosstype “riself4” assumes that each line is formed by crossing the four founders and then inbreeding. If you have multiple panels of two-way RIL, you need to split them apart as separate “riself” populations. 

You could maybe combine them after doing calc_genoprob, for QTL mapping, but R/qtl2 doesn’t currently provide any functional to support the joint analysis of multiple populations.

karl

李凯

unread,
Jan 16, 2021, 2:32:46 PM1/16/21
to rqtl2...@googlegroups.com
ok thank you very much! Sorry for disturbing!

Karl Broman <kbr...@gmail.com> 于2021年1月16日周六 下午8:24写道:
You received this message because you are subscribed to a topic in the Google Groups "R/qtl2 discussion" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/rqtl2-disc/lF8F4UNQI_g/unsubscribe.
To unsubscribe from this group and all its topics, send an email to rqtl2-disc+...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rqtl2-disc/781e69de-8454-4c26-a7ac-298e918251fcn%40googlegroups.com.
Reply all
Reply to author
Forward
0 new messages