Yes,
$kotirovka - it's variable of the exchange rate
when we did the script, faced with the fact that bitstamp api only gives the rate of Fed dollar
and onBtc-e Euro is not so easy withdraw. Easier - through the dollar. (maybe now the situation has changed)
+ There was a need to count in russian rubls (when possible).
so this code. Its not perfect, but its must work.
I will translate comments into English, but it will be later.