You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a question on how the tkey argument is used in scvelo.tl.velocity_graph. Based on the documentation, my impression of the use case is when one has time-course data, where each cell is associated with a time point (e.g. day 1, 3, 5). Intuitively, the information of time can be used to "prune" unlikely transition when constructing the velocity graph, e.g. when the cells are very far apart or reverse in time, which should create a more informative velocity graph.
However, my understanding seems to be different from what the code is doing (here). The key line is neighs_idx = np.unique(np.concatenate([neighs_idx, t1_idx])) , where for each cell, the neighbors are defined to be both its iterative neighbors (as identified by get_iterative_indices) and a sample of the cells at the subsequent time point. I'm wondering if it'd make more sense to define its neighbors as the intersection between the iterative neighbors and cells at the subsequent time point, rather than the union? Perhaps something like neighs_idx = np.intersect1d(neighs_idx, t1_idx), where t1_idx = np.where(self.t0 == t1)[0]?
In general, I'm also wondering if there are any best practices for scvelo regarding time-course data?
Thanks!
The text was updated successfully, but these errors were encountered:
A follow up question on the plotting function for velocity graph (scvelo.pl.velocity_graph). I noticed here that in the default setting, the plotting function doesn't plot the transition matrix based on adata.uns['velocity_graph'], but instead run transition_matrix. I'm wondering how is this different from running scvelo.tl.velocity_graph?
Suppose one has already ran scvelo.tl.velocity_graph, should one specify which_graph='velocity_graph' when running scvelo.pl.velocity_graph?
Hi!
I have a question on how the
tkey
argument is used inscvelo.tl.velocity_graph
. Based on the documentation, my impression of the use case is when one has time-course data, where each cell is associated with a time point (e.g. day 1, 3, 5). Intuitively, the information of time can be used to "prune" unlikely transition when constructing the velocity graph, e.g. when the cells are very far apart or reverse in time, which should create a more informative velocity graph.However, my understanding seems to be different from what the code is doing (here). The key line is
neighs_idx = np.unique(np.concatenate([neighs_idx, t1_idx]))
, where for each cell, the neighbors are defined to be both its iterative neighbors (as identified byget_iterative_indices
) and a sample of the cells at the subsequent time point. I'm wondering if it'd make more sense to define its neighbors as the intersection between the iterative neighbors and cells at the subsequent time point, rather than the union? Perhaps something likeneighs_idx = np.intersect1d(neighs_idx, t1_idx)
, wheret1_idx = np.where(self.t0 == t1)[0]
?In general, I'm also wondering if there are any best practices for scvelo regarding time-course data?
Thanks!
The text was updated successfully, but these errors were encountered: