Oblitervict

SmartPCA setup

Apr 6th, 2026
224
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 1.73 KB | None | 0 0
  1. 1. Created a smartpca reference population list
  2.  
  3. File used:
  4.  
  5. smartpca_refs.txt
  6.  
  7. This file contained the modern reference populations used to define the PCA axes, along with the modern target sample included as a reference in this run.
  8.  
  9. 2. Created a convertf keep list
  10.  
  11. File used:
  12.  
  13. convertf_keep_projected.txt
  14.  
  15. This file contained:
  16.  
  17. all populations included in the smartpca reference list
  18. additional ancient samples retained in the subset for projection
  19.  
  20. The ancient samples were kept in the dataset but not included in the smartpca reference list.
  21.  
  22. 3. Prepared a convertf parameter file
  23.  
  24. File:
  25.  
  26. convertf_subset.par
  27.  
  28. Structure:
  29.  
  30. genotypename: merged_input.geno
  31. snpname: merged_input.snp
  32. indivname: merged_input.ind
  33. outputformat: EIGENSTRAT
  34. genotypeoutname: pca_subset.geno
  35. snpoutname: pca_subset.snp
  36. indivoutname: pca_subset.ind
  37. poplistname: convertf_keep_projected.txt
  38. hashcheck: NO
  39.  
  40. 4. Ran convertf
  41.  
  42. convertf -p convertf_subset.par > convertf_subset.log 2>&1
  43.  
  44. This generated the PCA subset used in the next step.
  45.  
  46. 5. Prepared a smartpca parameter file
  47.  
  48. File:
  49.  
  50. smartpca.par
  51.  
  52. Structure:
  53.  
  54. genotypename: pca_subset.geno
  55. snpname: pca_subset.snp
  56. indivname: pca_subset.ind
  57.  
  58. evecoutname: pca_output.evec
  59. evaloutname: pca_output.eval
  60.  
  61. poplistname: smartpca_refs.txt
  62.  
  63. lsqproject: YES
  64. numoutevec: 10
  65. numthreads: 10
  66. numoutlieriter: 0
  67.  
  68. 6. Ran smartpca
  69.  
  70. smartpca -p smartpca.par > smartpca.log 2>&1
  71.  
  72. 7. Output files generated
  73.  
  74. pca_output.evec
  75. pca_output.eval
  76.  
  77. This run used the populations in smartpca_refs.txt to define the PCA axes, while samples retained through convertf_keep_projected.txt but absent from the smartpca reference list were projected.
Advertisement
Add Comment
Please, Sign In to add comment