R/qtl2 version 0.22

135 views
Skip to first unread message

Karl Broman

unread,
May 22, 2020, 2:12:45 AM5/22/20
to R/qtl2 discussion
We've released a new version of R/qtl2. Install the update with

    update.packages(ask=FALSE, repos="https://rqtl.org/qtl2cran")

Or install from scratch with

    install.packages("qtl2", repos="https://rqtl.org/qtl2cran")

The changes are shown below. R/qtl2fst and R/qtl2convert have also been updated.

karl

---

Major changes

  • Added some functions for diagnostics: recode_snps(),
    calc_raw_het(), calc_raw_geno_freq(), calc_raw_maf(), and
    calc_raw_founder_maf().

  • Added argument blup to fit1(), for getting BLUPs for a single
    fixed QTL position. At present, just gives estimates and
    coefficients by calling scan1blup() with a single position.

  • pull_genoprobpos() can now take either a marker name (as before) or
    a set of map, chromosome, and position (from which it uses
    find_marker() to get the marker name).

  • Added plot function for the results of compare_geno(). (Plots
    histogram of upper triangle.)

  • Added functions n_founders() and founders() for getting the
    number of founders and the founder strain names for a cross2 object.

  • scan1() now takes an optional hsq argument, so that the residual
    heritability may be specified rather than estimated.

Minor changes

  • write_control_file() now allows cross info codes with a cross info
    file (previously only allowed with a covariate). read_cross2()
    gives a warning if there are cross info conversion codes but more
    than one cross info column.

  • Small fix in read_cross2() to allow multiple cross info covariates.

  • Added a check that the founder genotypes have the same strain IDs on
    each chromosome.

  • convert2cross2() now includes alleles component even if it
    wasn't present as an attribute.

  • Added function sdp2char() for converting numeric SDP codes to
    character strings like "ABC|DEFGH".

  • Updated mouse gene database with 2019-08-12 data from
    MGI.

  • get_common_ids() strips off names from output, just in case.

  • Added internal functions rqtl1_crosstype() and rqtl1_chrtype().

Bug fixes

  • Fixed typo in help for scan1() and related functions.

  • genoprob_to_snpprob() was giving an error if you gave a cross2
    object in place of a snpinfo table and it had monomorphic markers.

  • Fixed problem with weights in scan1() and related functions when
    their derived from table(). Make sure they're a plain numeric
    vector, not an array.

  • Fixed check_cross2(): the check for invalid genotypes wasn't
    happening.

  • Better error message for the case that there are no markers in
    common between map and genotypes.

  • extract_dim_from_header(), used by read_cross2() and read_csv(),
    now just looks for the number part in the rest of the line.

  • maxlod() now handles missing values (forcing na.rm=TRUE). If all
    values are missing it gives a warning and returns -Inf.
    [Fixes Issue #134.]

  • In max_scan1(), treat the case that the input has no column names.
    [Fixes Issue #133.]

  • max_scan1() was giving a messed up error message if lodcolumn
    was out of range. [Fixes Issue #132.]

  • Revised the script inst/scripts/create_ccvariants.R to capture all
    of the consequences and genes for each SNP (rather than just the
    first), and fixing a bug that prevented capture of indels from
    chromosomes 6-X. Consequently, revised the example SQLite database
    extdata/cc_variants_small.sqlite and associated tests.

Soren

unread,
May 26, 2020, 1:51:11 AM5/26/20
to R/qtl2 discussion
Dear Carl, 
after I updated the qtl2 package, I can't seem to load it any more. My R is 3.6.3 and R studio is 1.3.959. I get the following error when I load the package:

> install.packages("qtl2", repos="https://rqtl.org/qtl2cran")
Installing package into ‘/Users/dqz393/Library/R/3.6/library’
(as ‘lib’ is unspecified)
Content type 'application/octet-stream' length 2605709 bytes (2.5 MB)
==================================================
downloaded 2.5 MB


The downloaded binary packages are in
/var/folders/rx/xb_n10_n6vn5dby079nyzghd3qnd_m/T//RtmpDdUXIZ/downloaded_packages

> library(qtl2)
Error: package or namespace load failed for ‘qtl2’ in dyn.load(file, DLLpath = DLLpath, ...):
 unable to load shared object '/Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so':
  dlopen(/Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so, 6): Symbol not found: ____chkstk_darwin
  Referenced from: /Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so
  Expected in: /usr/lib/libSystem.B.dylib
 in /Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so

It seem like it cannot find the file.
I've tried to uninstall both the package and R.
Thanks in advance!
Søren

Karl Broman

unread,
May 26, 2020, 7:41:59 AM5/26/20
to R/qtl2 discussion

What version of Mac OS X are you using?
Can you show me the output of R.version?

karl

Soren

unread,
May 26, 2020, 8:00:07 AM5/26/20
to R/qtl2 discussion
Hi again, thanks for your quick reply!
I'm running on MacOS Sierra, version 10.12.6.

I get the following when I try to install it straight in to R console (R 3.6.3 GUI 1.70 El Capitan build (7735)):

R version 3.6.3 (2020-02-29) -- "Holding the Windsock"
Copyright (C) 2020 The R Foundation for Statistical Computing
Platform: x86_64-apple-darwin15.6.0 (64-bit)

[R.app GUI 1.70 (7735) x86_64-apple-darwin15.6.0]

[Workspace restored from /Users/dqz393/.RData]
[History restored from /Users/dqz393/.Rapp.history]

> install.packages("qtl2", repos="https://rqtl.org/qtl2cran")
Installing package into ‘/Users/dqz393/Library/R/3.6/library’
(as ‘lib’ is unspecified)
Content type 'application/octet-stream' length 2605709 bytes (2.5 MB)
==================================================
downloaded 2.5 MB


The downloaded binary packages are in
/var/folders/rx/xb_n10_n6vn5dby079nyzghd3qnd_m/T//Rtmp98QJ01/downloaded_packages
> library(qtl2)
Error: package or namespace load failed for ‘qtl2’ in dyn.load(file, DLLpath = DLLpath, ...):
 unable to load shared object '/Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so':
  dlopen(/Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so, 6): Symbol not found: ____chkstk_darwin
  Referenced from: /Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so
  Expected in: /usr/lib/libSystem.B.dylib
 in /Users/dqz393/Library/R/3.6/library/qtl2/libs/qtl2.so

Søren

On Friday, May 22, 2020 at 4:12:45 PM UTC+10, Karl Broman wrote:

Karl Broman

unread,
May 26, 2020, 8:06:46 AM5/26/20
to R/qtl2 discussion
You could try installing it from source

   install.packages(“qtl2”, repos=“https://rqtl.org/qtl2cran”, type=“source”)

You’d need to install Xcode. At the command line:

   xcode-select --install

karl

Karl Broman

unread,
May 26, 2020, 11:04:23 AM5/26/20
to R/qtl2 discussion
I think the trouble is that I compiled the package on MacOS Catalina, 10.15, and it's apparently not backward-compatible. Looks like CRAN is using 10.13 to build packages (https://mac.r-project.org).

I'll see if I can build useable versions. But it seems like it's time for me to put qtl2 onto CRAN.

I'm sorry for these problems,
karl

On Tuesday, May 26, 2020 at 7:00:07 AM UTC-5, Soren wrote:

Soren

unread,
May 26, 2020, 10:16:11 PM5/26/20
to R/qtl2 discussion
Hi again, installing it straight from the source did the trick! Thanks a lot for your help!
kind regards,
Søren

On Friday, May 22, 2020 at 4:12:45 PM UTC+10, Karl Broman wrote:

Ramesh S. Bhat

unread,
May 29, 2024, 3:29:06 AMMay 29
to rqtl2...@googlegroups.com
Dear Dr. Karl,
May I know the functions to get BLUPs for a single fixed QTL position?
I think scan1blup() and fit1() with an argument blup are no longer active.
Kind regards,
 



--
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/3d5d52e5-996a-4306-9212-badadc718c11%40googlegroups.com.


--
Dr. Ramesh S. Bhat
Professor (Genetics and Plant Breeding/Biotechnology)
Editor, Publication Centre
University of Agricultural Sciences, Dharwad
PIN: 580 005, Dharwad, Karnataka, India
Ph: +91-836-2214288, Mobile: +91-9945667300

Karl Broman

unread,
May 29, 2024, 6:56:03 AMMay 29
to R/qtl2 discussion
You can use fit1() to get BLUPs for a fixed position.

karl

Ramesh S. Bhat

unread,
May 29, 2024, 7:01:14 AMMay 29
to rqtl2...@googlegroups.com
But, I get the following result

 ?fit1
No documentation for ‘fit1’ in specified packages and libraries:
you could try ‘??fit1’

Ramesh S. Bhat

unread,
May 29, 2024, 7:05:24 AMMay 29
to rqtl2...@googlegroups.com
I shall try again.


On Wed, May 29, 2024 at 4:26 PM Karl Broman <kbr...@gmail.com> wrote:

Karl Broman

unread,
May 29, 2024, 7:09:51 AMMay 29
to R/qtl2 discussion
You maybe need to load the package.

    library(qtl2)

karl

Ramesh S. Bhat

unread,
May 29, 2024, 7:11:56 AMMay 29
to rqtl2...@googlegroups.com
Yes, you are right.
Is there any function in the package "qtl" to get the blup?


Dan Gatti

unread,
May 29, 2024, 7:19:15 AMMay 29
to rqtl2...@googlegroups.com

I don’t believe that there is. I would use qtl2.

 

Dan

---

The information in this email, including attachments, may be confidential and is intended solely for the addressee(s). If you believe you received this email by mistake, please notify the sender by return email as soon as possible.

Karl Broman

unread,
May 29, 2024, 7:20:35 AMMay 29
to R/qtl2 discussion
No.
karl

Reply all
Reply to author
Forward
0 new messages