Skip to content

Commit

Permalink
Update fit.py
Browse files Browse the repository at this point in the history
  • Loading branch information
yiwang12 authored Jul 25, 2023
1 parent c3577a7 commit b19eb41
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions mouse_sagittal_data_analysis_smallData/fit.py
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@
import pandas as pd
import sys
import pickle
import random

########################################################################
########################################################################
Expand Down Expand Up @@ -56,6 +57,16 @@
list_sampleID=process_multiSample.get_listSampleID(list_D)




# inducing points, 35% of total spots for each sample
for ksample in range(0,nsample):
random.seed(10)
ninduced=round(list_D[ksample]['X'].shape[0] * 0.35)
print(ninduced)
D=list_D[ksample]
list_D[ksample]["Z"]=D['X'][random.sample(range(0, D['X'].shape[0]-1), ninduced) ,:]

########################################################################3
################### step 1 initialize model
########################################################################
Expand Down

0 comments on commit b19eb41

Please sign in to comment.