Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

load local .bw data #5

Open
xpf10 opened this issue Oct 17, 2024 · 2 comments
Open

load local .bw data #5

xpf10 opened this issue Oct 17, 2024 · 2 comments

Comments

@xpf10
Copy link

xpf10 commented Oct 17, 2024

it is difficult to load local .bw file.

@sehilyi
Copy link
Member

sehilyi commented Oct 17, 2024

Could you please elaborate on what makes it difficult for you to load the .bw file?

@xpf10
Copy link
Author

xpf10 commented Oct 18, 2024

Using the same code, the local bw file can be successfully visualised on windows platform but not on ssh linked linux platform.
code:

import streamlit as st
import gosling as gos
import streamlit_gosling as st_gos
size = 500
# create visualization using gosling
@st.cache_data
def chart():

    bigwig_url="./ExcitatoryNeurons-insertions_bin100_RIPnorm.bw"
    data_bw = gos.bigwig(url=bigwig_url, column="position", value="value")

    excitatory_neurons = gos.Track(data_bw).mark_bar().encode(
        x="position:G",
        y="value:Q",
    ).properties(height=100)
    return gos.stack(excitatory_neurons).properties(
        xDomain=gos.GenomicDomain(chromosome="chr1", interval=[0, 100000000]),
    )

st_gos.from_gos(
    spec=chart(),
    id='id',
    height=size+ 100
)

on the windows:
�����ͼ_20241018152135
on the linux:
�����ͼ_20241018152555

It is difficult to check if there's a problem with the file path

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants