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

SVD from matrix #27

Open
YeCheng57 opened this issue Mar 14, 2021 · 0 comments
Open

SVD from matrix #27

YeCheng57 opened this issue Mar 14, 2021 · 0 comments

Comments

@YeCheng57
Copy link

NUM_SAMPLES=ls *.norm.cov.bed | wc -l | awk '{print $1}' NUM_WINDOWS=ls *.norm.cov.bed | head -n 1 | xargs awk '$1 != "X" && $1 != "Y" && $NF == 0 {x++} END {print x}'`
echo -e "$NUM_SAMPLES\t$NUM_WINDOWS" >matrix.txt

ls *.norm.cov.bed | while read FILE
do
awk '$1 != "X" && $1 != "Y" && $NF == 0 { print $4 }' $FILE
| gawk -f $CLAMMS_DIR/transpose.gawk >>matrix.txt
done`
Actually, I wonder if the "$NF==0" should be "$NF !=0"? Now the matrix is one zero matrix!

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

1 participant