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

Bugs in Plotting trajectory trends function script #32

Closed
YubinXie opened this issue Feb 19, 2019 · 1 comment
Closed

Bugs in Plotting trajectory trends function script #32

YubinXie opened this issue Feb 19, 2019 · 1 comment

Comments

@YubinXie
Copy link

In the Plotting trajectory trends part, https://broadinstitute.github.io/wot/notebook/, error comes when I run the script:

AttributeError: module 'wot.ot' has no attribute 'compute_trajectory_trends_from_trajectory'

After I searched the source code, I found that wot.ot should be wot.tmap to get compute_trajectory_trends_from_trajectory function.

However, after fixing that, a new error comes

---------------------------------------------------------------------------
IndexError                                Traceback (most recent call last)
<ipython-input-20-b60afaa2d212> in <module>()
     24 # timepoints, means, variances = tmap_model.compute_trajectory_trends(ds, population)
     25 trajectory_ds = tmap_model.compute_trajectories({target_cell_set: all_populations[target_cell_set]})
---> 26 results = wot.tmap.compute_trajectory_trends_from_trajectory(trajectory_ds, ds)
     27 means, variances = results[0]
     28 timepoints = means.obs.index.values

~/.local/lib/python3.6/site-packages/wot/tmap/transport_map_util.py in compute_trajectory_trends_from_trajectory(trajectory_ds, ds)
     76     mean_list = []
     77     variance_list = []
---> 78     for j in range(trajectory_ds.X.shape[1]):
     79         mean_list.append(None)
     80         variance_list.append(None)

IndexError: tuple index out of range

The shape of trajectory_ds.X is (153545,), there is no second dimension. I am not able to fix this issue yet.

@joshua-gould
Copy link
Contributor

Thanks, I updated the python code.

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