Click to See Complete Forum and Search --> : Need formula help


JNelson
08-26-2003, 12:26 PM
I am trying to program a formula in esignal (a financial charting package).
What i am trying to do is create a simple formula that takes the price of crude oil, divided by 5.8 and then subtracting it from the price of Natural Gas.
The problem is, I am not familiar with Javascript. If anyone has the time to help me out, I would appreciate it.

John Nelson

pyro
08-26-2003, 12:43 PM
Try

<script type="text/javascript">
crude_oil_price = xx;
natural_gas_price = xx;
price = natural_gas_price - (crude_oil_price/5.8);
alert (price);
</script>