GithubHelp home page GithubHelp logo

Comments (10)

agrueneberg avatar agrueneberg commented on July 17, 2024

Hi Rosie,

could you please let me know what versions of the BEDMatrix package and its dependency, the crochet package (which contains the convertIndex function), you are using? You can copy and paste the following two lines into an R session:

packageVersion("BEDMatrix")
packageVersion("crochet")

Thanks,
Alex

from bedmatrix.

rosieli5 avatar rosieli5 commented on July 17, 2024

Hi Alex, here are the package versions below. Thank you!

Best,
Rosie

> packageVersion("BEDMatrix",lib.loc=pkgpath)
[1] ‘1.4.1’
> packageVersion("crochet",lib.loc=pkgpath)
[1] ‘2.1.0’

from bedmatrix.

agrueneberg avatar agrueneberg commented on July 17, 2024

Weird, crochet 2.1.0 should definitely contain the convertIndex function--it's even exported. What happens if you load the crochet package before the BEDMatrix package and run your example again?

library("crochet", lib.loc = pkgpath)
library("BEDMatrix", lib.loc = pkgpath)
mat <- BEDMatrix("test.bed")
mat[1:2,1:2]

from bedmatrix.

rosieli5 avatar rosieli5 commented on July 17, 2024

Aha, it worked. Thanks Alex!

Best,
Rosie

from bedmatrix.

agrueneberg avatar agrueneberg commented on July 17, 2024

You shouldn't have to load the crochet package manually, though... What version of R are you using? You can figure that out by copy and pasting version$version.string into your R session.

from bedmatrix.

rosieli5 avatar rosieli5 commented on July 17, 2024

True, not having to load it each time would be better. I have R version 3.5.1 (2018-07-02).

from bedmatrix.

agrueneberg avatar agrueneberg commented on July 17, 2024

Sorry, I cannot reproduce the problem on my end. Can you reproduce the problem on your end if you run the following code in a new R session?

pkgpath <- "please_fill_in"
library("BEDMatrix", lib.loc = pkgpath)
mat <- BEDMatrix("test.bed")
mat[1:2,1:2]

from bedmatrix.

rosieli5 avatar rosieli5 commented on July 17, 2024

I got the following message. Hmm it may be an issue with my environment?

Warning: namespace ‘crochet’ is not available and has been replaced
by .GlobalEnv when processing object ‘’
Error in convertIndex(x, i, "i", allowDoubles = allowDoubles) :
  could not find function "convertIndex"

from bedmatrix.

agrueneberg avatar agrueneberg commented on July 17, 2024

Sounds like there is a workspace image (a hidden file called .RData) in the directory from which you start your R session. You can either delete or rename the file before starting R, start R with the --no-restore option, run rm(list = ls()) after starting R, or start R from a different directory to get a clean environment.

from bedmatrix.

rosieli5 avatar rosieli5 commented on July 17, 2024

I tried rm(list=ls()), but it didn't seem to have worked. Thanks still!

from bedmatrix.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.