View full-text article in PMC Cancers (Basel). 2023 Mar 4;15(5):1601. doi: 10.3390/cancers15051601 Search in PMC Search in PubMed View in NLM Catalog Add to search Copyright and License information © 2023 by the authors. Licensee MDPI, Basel, Switzerland. This article is an open access article distributed under the terms and conditions of the Creative Commons Attribution (CC BY) license (https://creativecommons.org/licenses/by/4.0/). PMC Copyright notice Algorithm 1Btm2K(V,Kmin,Kmax). 1:Input: V∈R≥0N×M,1≤Kmin<Kmax≤min{N,M} 2:Parameters: T=numberofrunsforeachK 3:Vbig=Sampleswithmorethan5timestheaveragebitermsinV 4:V=Therest 5:fort=1,⋯,Tdo 6: V1,V2=splitVrandomlytotwoequalsizedsets 7: for k=Kmin,⋯,Kmax do 8: btm=BTM(k,V1⋃Vbig) 9: S[k,t]=btm.log-likelihood(V2) 10: btm=BTM(k,V2⋃Vbig) 11: S[k,t]=S[k,t]+btm.log-likelihood(V1) 12:K˜=arg mink(median(S[k,:])) 13:repeat 14: K*=K˜ 15: K˜=min{K<K*|Wilcoxons-rank-sum(S[K,:],S[K*,:])>0.05} 16:untilK˜<K* 17:returnK˜