Code Monkey home page Code Monkey logo

Comments (8)

nargesr avatar nargesr commented on July 26, 2024

Hi,
which version of PyWGCNA are you using? I believe I resolved this error in the latest version (V1.15.1)

you can install it using pip install PyWGCNA==1.15.1

from pywgcna.

RayRay-23 avatar RayRay-23 commented on July 26, 2024

Hi
I check the version and it is V1.15.1. Another issue is I just find the shape of the data I downloaded is different from your description in tutorials, which should be 193, 5548 but turn out 192, 55449. The gene_id format also different from normal (ENSMUSG00000000003.15). Could you please check that if it could be the reason? Thank you so much.

from pywgcna.

nargesr avatar nargesr commented on July 26, 2024

can you also check the version of gseapy package?

I'm a little confused about your next question...
The gene expression data is a table which the rows are samples and columns are genes (similar to what we have in the tutorials)
column names should be gene id or a gene name or anything else you want, the main thing is that it should be unique.... so it doesn't matter if it's ENSMUSG00000000003.15 or ENSMUSG00000000003 or Pbsn as long as it's unique

from pywgcna.

RayRay-23 avatar RayRay-23 commented on July 26, 2024

Hi,
I also check the version of gseapy (0.14.0) and every other dependent packages. But still I get the error below:

``
pyWGCNA_5xFAD.analyseWGCNA(geneList=geneList)
Analysing WGCNA...
Calculating module trait relationship ...
Done..

Adding (signed) eigengene-based connectivity (module membership) ...
Done..

Updating gene information based on given gene list ...
Done..

plotting module heatmap eigengene...
Done..

plotting module barplot eigengene...
Done..

doing Enrichr GO analysis for each module...
Traceback (most recent call last):

File "/var/folders/92/y1bxhnw57djg_97p9x5sr2sc0000gn/T/ipykernel_50284/269853499.py", line 1, in
pyWGCNA_5xFAD.analyseWGCNA(geneList=geneList)

File "/opt/anaconda3/lib/python3.9/site-packages/PyWGCNA/wgcna.py", line 441, in analyseWGCNA
self.functional_enrichment_analysis(type="GO",

File "/opt/anaconda3/lib/python3.9/site-packages/PyWGCNA/wgcna.py", line 3030, in functional_enrichment_analysis
enr = gp.enrichr(gene_list=geneModule,

TypeError: enrichr() got an unexpected keyword argument 'description'
``

In addition, when I try to run

``
pyWGCNA_5xFAD.CoexpressionModulePlot(modules=["darkgray"], numGenes=10, numConnections=100, minTOM=0)
Traceback (most recent call last):

File "/var/folders/92/y1bxhnw57djg_97p9x5sr2sc0000gn/T/ipykernel_50284/1756115348.py", line 1, in
pyWGCNA_5xFAD.CoexpressionModulePlot(modules=["darkgray"], numGenes=10, numConnections=100, minTOM=0)

File "/opt/anaconda3/lib/python3.9/site-packages/PyWGCNA/wgcna.py", line 3319, in CoexpressionModulePlot
net.show(f"{self.outputPath}/figures/network/{file_name}.html")

File "/opt/anaconda3/lib/python3.9/site-packages/pyvis/network.py", line 551, in show
self.write_html(name, local)

File "/opt/anaconda3/lib/python3.9/site-packages/pyvis/network.py", line 536, in write_html
with open(f"{tempdir}/{name}", "w+") as out:

FileNotFoundError: [Errno 2] No such file or directory: ".//Users/Raymond/Library/CloudStorage/OneDrive-TheUniversityofQueensland/Documents/figures/network/darkgray.html"
``

Do you have any suggestions?
By the way, thank you for developing this good python version and I really wish I could use it.

from pywgcna.

tyaoi avatar tyaoi commented on July 26, 2024

Hi !

I ended up downgrading gseapy to ver. 0.10.5 to resolve this error.
The steps to do so are as follows

pip install pywgcna
pip uninstall gseapy
pip install pywgcna==0.10.5

However, there seems to have been an improvement in the corrected p-values in ver 0.13.0 and above, so support for 0.14.0 is desired.

from pywgcna.

RayRay-23 avatar RayRay-23 commented on July 26, 2024

Hi tyaoi,

It does work for me. Thank you so much. Just a kind reminder for others that it should be "pip install gseapy==0.10.5".

For someone who also has problems in network plotting by pyWGCNA_5xFAD.CoexpressionModulePlot, you can try to delete the "self.outputPath" in line 3319 in wgcna.py file, and the figure will be output in your current working directory. It works for me.

Many thanks
Ray

from pywgcna.

nargesr avatar nargesr commented on July 26, 2024

Hi!

sorry for the late respond! There is one issue with the new version of gseapy precisely the dotplot function that's why I didn't update the function yet!
I will update it once that problem resolved

for CoexpressionModulePlot(), it seems there is a problem with your path {self.outputPath}/figures/network/{file_name}.html. I would recommend printing the path to make sure your path exists.

from pywgcna.

RayRay-23 avatar RayRay-23 commented on July 26, 2024

Thank you, Narges!

from pywgcna.

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.