Search
Question: [Solved] GSEAlm: failed importing gsealmPerm function
0
3.5 years ago by
kmezhoud10
Tunisia
kmezhoud10 wrote:

Dear All,

I would like to import gsealmPerm function from GSEAlm package:

I added to DESCRIPTION file  :    imports: GSEAlm

I added to NAMESPACE file:       importFrom (GSEAlm, gsealmPerm)

And I used the function as:       GSEAlm::gsealmPerm(arguments.....)

but it yet failed to run function. When I load GSEAlm package it works.

When is there a NON-exportable function from package how can I use it without to load all functionalities of package?

Thanks

Karim

modified 3.5 years ago • written 3.5 years ago by kmezhoud10
0
3.5 years ago by
Martin Morgan ♦♦ 21k
United States
Martin Morgan ♦♦ 21k wrote:

When I look at the source code for the GSEAlm package, I see a function called gsealmPerm. Is this the function you mean? If so, your problem is simple typo. DESCRIPTION

Imports: GSEAlm

NAMESPACE:

importFrom(GSEAlm, gsealmPerm)

.R:

gsealmPerm(...)

Or is there another problem, e.g., the function fails in your own code? If so, then please add to your question by including the exact error message.

0
3.5 years ago by
kmezhoud10
Tunisia
kmezhoud10 wrote:

Dear Dr Morgan,

Yes I did that           gseaPerm

The error message was:

Error in match(x, table, nomatch = 0L) :   could not find function "varLabels"

Finally the prblm comes from an other function

Biobase::varLabels

which was silenced by

if(inherits(try(pVals<-GSEAlm::gsealmPerm(eSet,coVariables,mSigDB_forGeneList,nperm= permutVal, na.rm=TRUE), silent=TRUE),"try-error"))
{tkmessage(message="ERROR"}.

Thanks

Karim