Right now, I have data of valence and activation, but how to calculate the affect spin? I don't understand the vector calculation, could someone help me out using the formula below?
Code:
* Example generated by -dataex-. To install: ssc install dataex
clear
input double(valence activation)
1.4   4
  3 2.4
1.6 2.4
3.2 3.8
  1   4
1.2 3.4
  3   5
  .   .
1.8 3.8
  2   4
  1 3.2
  5 4.8
2.4 3.6
  1 4.8
1.8   4
  3   4
2.2   4
  3 3.6
  3   4
1.6   4
  2   4
3.4 3.4
3.4 3.4
1.2   4
1.6 4.2
1.4   3
1.8 4.2
1.8   4
  2 4.2
  2 2.6
1.2 3.6
  3   4
  2   4
4.4   4
  1 3.4
1.6 3.2
  .   .
3.2 3.4
  1   4
2.4 3.4
  2   4
  .   .
  3   3
  .   .
  2 3.6
3.8 3.4
1.6 3.8
2.4 1.6
  2   3
  2   4
1.6 3.8
1.2 3.2
  1   4
  1   4
  2   4
1.2 4.8
1.2   3
1.8   5
  1   5
2.2 3.8
  3 4.4
1.6   4
1.2   5
2.2 3.2
1.8   4
1.6 3.8
1.6   3
  1   2
  3 3.4
2.8   4
2.8   3
2.2   4
1.4 3.4
2.6 4.6
  3 3.8
  .   .
1.6 3.4
1.4   4
  2   4
1.6   4
1.6 3.4
1.4   4
1.2   4
3.2 3.8
2.6   5
  2 4.2
2.6   4
  3   5
2.2   5
2.2   5
1.6 2.8
1.4 4.2
1.2 2.8
1.4 3.4
1.4 3.6
1.6   4
1.4   4
3.8 2.6
  4 2.8
  4 2.4
end
Array

https://www.ncbi.nlm.nih.gov/pmc/articles/PMC4649026/