Error in cnetplot enrichplot package
0
0
Entering edit mode
4 weeks ago
Farhad • 0

Hello I have a question about cnetplot in enrichplot When I use it Show me this error

Error in graph_from_data_frame(d = d , directed = directed, vertices = vertices) : the data frame should contain at least two columns

Please help

R • 525 views
ADD COMMENT
0
Entering edit mode

The error message is pretty clear, and without more context, we cannot really help you here.

ADD REPLY
0
Entering edit mode

My friend do this analysis with exact same Data frame without any error

ADD REPLY
0
Entering edit mode

That kind of context does not really help. Please show us:

  1. "this analysis" - do you mean just the exact line of code above or is there more to it that you're just summarizing here?
  2. "exact same Data frame" - unless your friend ran the analysis on the same R session you're using right now immediately before you, there is no "exact same Data frame".
  3. "without any error" - we could take your word for this but showing some sort of code + example input + output will actually help.

So the only context here is that your friend ran some code on some machine and it worked and you are trying to run similar code but are running into problems. Show us your full code and excerpts from your data frame or better yet, sit with your friend and compare notes.

ADD REPLY
0
Entering edit mode

See my friend sent me his data frame for me

ADD REPLY
0
Entering edit mode

How does one "send" an in-memory data structure?

ADD REPLY
0
Entering edit mode

We write it to csv and then send it via email

ADD REPLY
0
Entering edit mode

I check dataframe it has more than 2 columns

ADD REPLY
0
Entering edit mode

Show us the exact call to cnetplot() with a sample of all input parameters. Did you compare notes with your friend?

ADD REPLY

Login before adding your answer.

Traffic: 2384 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6