Skip to content

Commit

Permalink
Create Kstar_correlation.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
gf777 committed Mar 21, 2021
1 parent 7b739c1 commit 082d6c5
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions scripts/Kstar_correlation.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#!/bin/bash

#cut -f3-5 ${2} | paste ${1} - | awk '{if($3==0){a="NA"}else{a=$5};if($6==0){b="NA"}else{b=$8}; print a"\t"b}' | sort -nk1 -nk2 | uniq -c | sed "s/^[ ]*//" | tr -s " " | tr [:blank:] \\t

cut -f3-5 ${2} | paste ${1} - | awk '{if($3==0){a="NA"}else{a=$5};if($6==0){b="NA"}else{b=$8}; dups[a"\t"b]++} END{for (num in dups) {printf dups[num]"\t"num"\n"}}' | sort -nrk1 -nk2

0 comments on commit 082d6c5

Please sign in to comment.