Create an IntAct shortlabel for a given interaction (ie. a set of [protein, role] ).
- Stategy -
Protein's role can be either: bait, prey or neutral the interaction shortlabel has the following patter: X-Y-Z
with a limit in length of 20 caracters. TODO: do not hard code that ! Could be fetched from the
DatabaseInspector.
X is (in order of preference): 1. the gene name of the bait protein 2. the gene name of a prey protein (the first
one in alphabetical order) 3. the gene name of a neutral protein (the first one in alphabetical order)
Y is : 1. the gene name of a prey protein (the first one in alphabetical order or second if the first has been
used already) 2. the gene name of a neutral protein (the first one in alphabetical order or second if the first
has been used already) Z is : an Integer that gives the number of occurence in intact.
eg. 1. bait(baaa), prey(paaa, pbbb, pccc), neutral(naaa) should gives us: baaa-paaa-1
2. bait(baaa), prey(), neutral(naaa) should gives us: baaa-naaa-1
3. bait(), prey(paaa, pbbb, pccc), neutral(naaa) should gives us: paaa-pbbb-1
4. bait(), prey(paaa), neutral(naaa) should gives us: paaa-naaa-1