NZD pushing towards resistance level of 0.7250, a break of which would target 0.7300; NZDAUD trading at 0.9540 and has strong support in this trading area; NZ CPI along with Trump policy announcements key data releases for this week

By Howard Willcox*:

Main event over the last few days has been the inauguration of President Trump and the implementation of his policies and how they will begin to affect financial markets. Already he has signed an executive order for the US to back out of the TPP trade deal as well as announcing over the weekend that he is seeking to renegotiate the North American Free Trade Agreement. Investors are now looking for details on previous promises to boost growth and Government spending. He has also commented that tax cuts are coming and that regulation will be cut by 75%. With data showing that the US is almost at full employment, Trumps expansionist policies are likely to lead to a jump in growth with a corresponding boost to inflation, which may bring forward rate increases already signalled by the Federal Reserve. This would elevate the USD amongst its major trading partners Japan and the Eurozone, as those economies still remain stagnant and the differential between US GDP starts to increase.

Major Announcements last week:

  • UK Average Earnings 2.8% vs 2.6% expected
  • UK Claimant Count -10.1k vs +4.6k expected
  • US Inflation 0.3% as expected
  • Bank of Canada leave rates unchanged
  • Australia Employment Change 13.5k vs 10.2k expected
  • Australian Unemployment Rate 5.8% vs 5.7%
  • Canadian Manufacturing Sales 1.5% vs 0.2% expected
  • ECB leave rates unchanged
  • Chinese GDP 6.8% vs 6.7% expected
  • UK Retail Sales -1.9% vs -0.1% expected
  • Canadian Inflation -0.2% vs 0.0% expected

NZD/USD

The New Zealand dollar ranged between 0.7178-0.7228 overnight, it is currently at 0.7234 and looks solid against the weaker USD we expect the New Zealand dollar to push towards resistance of 0.7250 a break of which would target 0.7300. Thursday’s CPI release, if on the upside of expectations, may well provide the push for a move into the 0.7300 region, as long as the USD remains at current levels.

DIRECT FX Current level Support Resistance Last wk range
NZD / USD 0.7232 0.7185 0.7300 0.7108 – 0.7263

NZD/AUD (AUD/NZD)

The new Zealand dollar continues to trade around the 0.9540 (1.0482) and remains well supported on this cross, although the firmer metals prices have helped the Australian dollar, the continuing solid Global Dairy auction results have been New Zealand dollar supportive balancing the equation and leaving the other factors such as interest rate differentials and economic data to tilt the balance in the New Zealand dollar’s favour.

DIRECT FX Current level Support Resistance Last wk range
NZD / AUD 0.9543 0.9400 0.9685 0.9463 – 0.9559
AUD / NZD 1.0479 1.0325 1.0638 1.0462 – 1.0568

NZD/GBP (GBP/NZD)

Trading at 0.5782 (1.7295) as the New Zealand dollar has weakened from an overnight high of (1.7224) 0.5805 as the UK Pound firmed against most of its trading partners. The NZD remains favoured on this cross given the more benign political conditions and more resilient economy.

DIRECT FX Current level Support Resistance Last wk range
NZD / GBP 0.5779 0.5650 0.5850 0.5764 – 0.5923
GBP / NZD 1.7303 1.7094 1.7700 1.6884 – 1.7349

 NZD/CAD

Opened around 0.9577 and is currently trading at 0.9570 after a 0.9613-0.9535 range last night, the trend is higher and we look for a break of 0.9635 over the next few days.

DIRECT FX Current level Support Resistance Last wk range
NZD / CAD 0.9570 0.9440 0.9635 0.9355 – 0.9612

NZD/EURO (EURO/NZD)

Sitting around the 0.6738 (1.4841) level after a 0.6681-0.6727 (1.4967-1.4864) move overnight , we target another move to the 0.6750 level later tonight and the New Zealand CPI data could push to the 0.6800(1.4705) mark.

DIRECT FX Current level Support Resistance Last wk range
NZD / EUR 0.6726 0.6666 0.6760 0.6682 – 0.6768
EUR / NZD 1.4866 1.4800 1.5000 1.4775 – 1.4966

NZD/YEN

Currently around 81.78 after ranging between 81.41-82.14 overnight, looks to be entering into a short term sideways trading pattern in an 81.45-82.50 band. We expect this band to hold over the next few days up to the CPI figure on Thursday.

DIRECT FX Current level Support Resistance Last wk range
NZD / YEN 81.68 81.00 82.50 80.97 – 82.85

AUD/USD

Traded in a 0.7550-0.7588 range overnight and is now around 0.7590 on the softer USD .The Australian dollar is underpinned by the ongoing higher prices in the coal and iron ore prices  and economic data for Q4 and Q1 should continue to show improvement. 0.7600 is the next port of call on the upside but this is a major level that has proved elusive in the past. The Australian dollar story is still subservient to USD moves not helped by the AAA rating regrade threat overhang. Any break of 0.7600 needs to be sustained for gains to extend towards the 0.7700 area.

DIRECT FX Current level Support Resistance Last wk range
AUD / USD 0.7576 0.7450 0.7640 0.7476 – 0.7608

AUD/GBP (GBP/AUD) 

Now at 0.6060 (1.6500) after a move between 0.6050-0.6114 (1.6528-1.6355) last night, the AUD has weakened on this cross over the last week, coming back from 0.6248 (1.6003) as the GBP has bounced…the AUD is still favoured but GBP could strengthen to the 1.68 (0.5952) level.

DIRECT FX Current level Support Resistance Last wk range
AUD / GBP 0.6057 0.5952 0.6200 0.6049 – 0.6226
GBP / AUD 1.6511 1.6129 1.6800 1.6061 – 1.6531

AUD/EURO (EURO/AUD)

Now sitting at 0.7047 (1.4191) after ranging between a narrow 0.7030-0.7069 (1.42224-1.4146) overnight, the EUR has staged a comeback over the last 3 days as the AUD has weakened back from 0.7105 (1.4075) , has potential to dip towards the 0.6968 region over the next few days especially if there is more news on increasing Eurozone inflation , but with base commodity prices remaining firm the AUD should hold above the 0.6950 (1.4388) level over the next few days.

DIRECT FX Current level Support Resistance Last wk range
AUD / EUR 0.7044 0.6950 0.7105 0.7032 – 0.7128
EUR / AUD 1.4196 1.4075 1.4388 1.4153 – 1.4224

AUD/YEN

Currently around 85.77 after an 86.52- 85.33 overnight range, with the 86.00 level broken and the JPY remaining well bid, a move to the 85.00 region is now on the cards especially given the 85.50 level has given way over the last 24 hrs. The Australian dollar has performed better during the day but on balance we look for further AUD weakness on this cross.

DIRECT FX Current level Support Resistance Last wk range
AUD / YEN 85.52 85.00 86.00 85.03 – 87.06

AUD/CAD

Now at 1.0042 after a range over the last 24 hrs of 1.0027-1.0102, the Australian Dollar has performed solidly against the CAD over the last week, coming from 0.9830 a week ago and we look for a move back over the 1.0100 level later today.

DIRECT FX Current level Support Resistance Last wk range
AUD / CAD 1.0023 0.9960 1.0178 0.9900 – 1.0174

————————————————————————————————————-

To subscribe to our free daily Currency Rate Sheet and News email, enter your email address here.

Email:  

————————————————————————————————————————–

Market commentary:

Main event over the last few days has been the inauguration of President Trump and the implementation of his policies and how they will begin to affect financial markets. Already he has signed an executive order for the US to back out of the TPP trade deal as well as announcing over the weekend that he is seeking to renegotiate the North American Free Trade Agreement. Investors are now looking for details on previous promises to boost growth and Government spending. He has also commented that tax cuts are coming and that regulation will be cut by 75%. With data showing that the US is almost at full employment, Trumps expansionist policies are likely to lead to a jump in growth with a corresponding boost to inflation, which may bring forward rate increases already signalled by the Federal Reserve. This would elevate the USD amongst its major trading partners Japan and the Eurozone, as those economies still remain stagnant and the differential between US GDP starts to increase.

Australia

The Australian market has remained resilient with equities remaining firm, underpinned by support in mining stocks as commodity prices stay buoyant.
Data last week showed that consumer spending remained above average in December with spending for the holiday period exceeding the 10 average for the month. As inflation and interest rates stay at record lows, leading to continued growth in house prices and better job prospects (after a poor start early in 2016) consumers retain the ‘feel-good” factor leading to the recovery in spending patterns.

New Zealand

We expect this week’s Q4 CPI data on Thursday to show that inflation is starting to tick up towards the bottom of the RBNZ’s target at around 1.1-1.2%. Continuing house price increases are joined by higher petrol prices and a tightening labour market, helping to begin the trend of a gradual increase in underlying inflation over the coming months. Although the RBNZ is unlikely to pull the trigger on rate rises anytime soon, there is now no doubt that the next move is up and with the global inflation cycle turning, if the economy remains on track our pick is that a June increase of 0.25% may be the kick-off mark. Today’s announcement of an increase in the minimum wage by 50cents an hour to $15.75 from 1st April also provides another pointer. The New Zealand dollar remains well supported although as always susceptible to offshore swings, our relative political stability in an uncertain world and continued solid economic performance should ensure that any sell-offs in the New Zealand dollar will be shallow and short.

United States

The US remains in the throes of the Presidential handover, although the market is now starting to return to more fundamental issues such as corporate earnings results and data releases. Any large infrastructure sped-up will be positive for the US economy although as mentioned earlier with employment running close to capacity any major boost will be expansionary and likely to boost inflation and bring forward interest rate moves by the Fed. It is interesting to note that as the new US Trump administration ends its involvement with the TPP, China’s communist government is ramping up their efforts to engage with the rest of the world and advocating the advantages of free trade.

Europe

The EUR has held firm against a weaker USD as the Bundesbank’s latest report commented that German inflation could reach 2% in January. European stocks were lower as a report by European bank UBS recommended buying the Euro as it believes it is undervalued against the USD because of the more rapid euro-inflation growth. It also said that investors should begin to adjust to a less dovish ECB policy tone over the next 6 months and appreciate that the Euro remains extensively undervalued on a longer-term purchasing power parity basis. However to counter this view it should be remembered that there are upcoming elections in several EU member states that could present an unexpected outcome thus increasing political risk for the region and its currency unit.

United Kingdom

Tonight will see the UK Supreme Court decision on the UK government’s appeal of the High Court decision that recognised the right of the UK Parliament to have a vote on triggering the Brexit Article 50. With Parliament not keen on a “hard” Brexit this decision was seen as a major hurdle, however UK PM May, with her speech last week reframing the exit issue and providing more details on Brexit has to some extent side-lined this ruling. Interestingly President Trump has been supportive of forging a trade deal with the UK, but this cannot happen while the UK remains within the EU for the next 2 years. The UK economic data continues to be positive and remains supportive of the GBP, given the still anaemic recovery in other European countries.

Japan

Little news out for Japan, with today’s PMI data little changed from that expected at 52.3 coming in at 52.8. Japanese data has been more encouraging of late with the leading index upwardly revised in November from 102.70 to 102.8, up from a final October reading of 100.8 confirming a 15 month high. Japanese equity markets were softer for a second day as the JPY rallied to the highest level against the USD since November. Japanese trade balance is the only major release for later today, expected to show 270 bio up from the previous 153 bio figure.

Canada

Canadian data releases were light, but Canadian wholesale trade sales were lower than expected showing +0.2% against a forecasted  +0.5%…the motor vehicle and parts subsector posted the largest decline, while the miscellaneous subsector , including wholesalers of agricultural supplies, chemicals and allied products, paper, paper products and plastic products showed the largest increase.

Daily exchange rates

<!–

var root_url = "http://www.interest.co.nz/charts-csv/";
var tabs_count="7";
var csvfiles_loc= ["/charts-csv/chart_data/exchangerates/daily-usd.csv"," /charts-csv/chart_data/exchangerates/daily-aud.csv"," /charts-csv/chart_data/exchangerates/daily-twi.csv"," /charts-csv/chart_data/exchangerates/daily-yen.csv"," /charts-csv/chart_data/exchangerates/daily-yuan.csv"," /charts-csv/chart_data/exchangerates/daily-eur.csv"," /charts-csv/chart_data/exchangerates/daily-gbp.csv"];
var chart_title_arr= ["US dollar","Australian dollar","Trade weighted index","Japanese Yen","Chinese Yuan","Euro","British pound"];
var chart_subtitles_arr= ["Daily benchmark rate","Daily benchmark rate","Daily benchmark rate","Daily benchmark rate","Daily benchmark rate","Daily benchmark rate","Daily benchmark rate"];
var tab_titles_arr= ["US$","AU$","TWI","u00a5en","u00a5uan","u20acuro","GBP"];
var source_arr= ["RBNZ","RBNZ","RBNZ","RBNZ","RBNZ","RBNZ","RBNZ"];
var source_hyperlink_arr= ["8"];
var tabswidth="8";
var decimal_arr= ["4","4","4","2","2","4","4"];

// variable declaration
var xpad;
var padding_value=0;
var range_selector=0
var loc;
var updt;
var val_num;
var vi=0;
var max_val;
var x;

var finalAr = new Array();
for (var i = 0; i <= tabs_count; i++) {
finalAr[i] = new Array();
}
var flagAr = new Array();
for (var i = 0; i <= tabs_count; i++) {
flagAr[i] =[];
}
var yaxisAr = new Array();
for (var i = 0; i 536)
{
var b = arr.length – 536; // to get last 36 points
}
else if (arr.length < 536)
{
var b = 537 – arr.length;
}
else if(arr.length == 536)
{
var b=2;
}

// to generate the format for date representation in x axis

var timestamweek = 604800000;
var timestamday = 86400000;
var timestammonth30 = 2592000000;
var timestammonth31 = 2678400000;
var timestamyear = 31536000000;
var timestamquarterly = 7776000000;

for (var u=0;u<2;u++) {
arr[u] = parseLineCSV(arr[u]);
fomat= String(arr[u][0]);
var k=0;

do {
k++;
} while(fomat.charAt(k)!="-")
var k1 =k;

do {
k++;
} while(fomat.charAt(k)!="-")
var k2=k;

do {
k++;
} while(k<fomat.length)
var k3=k;

var dd= fomat.substring(0,k1);
var mm = fomat.substring(k1+1,k2);
var yy = "20"+fomat.substring(k2+1,k3+1);
var yy1=fomat.substring(k2+1,k3+1);

// conversion of months into numerical form

//+++++++++++++++++++++++++++++++++++
if (mm == "Jan")
{
mm= "01";
}
else if (mm == "Feb")
{
mm= "02";
}

else if (mm == "Mar")
{
mm= "03";
}

else if (mm == "Apr")
{
mm= "04";
}

else if (mm == "May")
{
mm= "05";
}

else if (mm == "Jun")
{
mm= "06";
}

else if (mm == "Jul")
{
mm= "07";
}

else if (mm == " Aug")
{
mm= "08";
}

else if (mm == "Sep")
{
mm= "09";
}

else if (mm == "Oct")
{
mm= "10";
}

else if (mm == "Nov")
{
mm= "11";
}

else if (mm == "Dec")
{
mm= "12";
}

// +++++++++++++++++++++++++++++++++++++++++++++++++++++++

var date2 = mm+"/"+dd+"/"+yy;

if (u==0)
{
var timestam1 = Date.parse(date2);
}
else if(u==1)
{
var timestam2 = Date.parse(date2);
}
}
var timestamvar = (timestam2- timestam1);
var flagAR_count=0;
for (var i=2;i<arr.length;i++) {
flagAR_count++;
var tempAr = new Array();
var tempAr1 = new Array();
arr[i] = parseLineCSV(arr[i]);
if (arr[i]!='')
{

fomat= String(arr[i][0]);
replic=String(arr[i][0]);
var k=0;

do {
k++;
} while(fomat.charAt(k)!="-")
var k1 =k;

do {
k++;
} while(fomat.charAt(k)!="-")
var k2=k;

do {
k++;
} while(k<fomat.length)
var k3=k;

var dd= fomat.substring(0,k1);
var mm = fomat.substring(k1+1,k2);
var current_year=""+new Date().getFullYear();
var c_year=Number(current_year.substring(2,4));
var c_data=Number(''+fomat.substring(k2+1,k3+1));
if(c_data c_year)
{
var yy = “19”+fomat.substring(k2+1,k3+1);
}
else if(c_data == c_year)
{
var yy = “20”+fomat.substring(k2+1,k3+1);
}
// conversion of months into numerical form

//+++++++++++++++++++++++++++++++++++
if (mm == “Jan”)
{
mm= “01”;
}
else if (mm == “Feb”)
{
mm= “02”;
}

else if (mm == “Mar”)
{
mm= “03”;
}

else if (mm == “Apr”)
{
mm= “04”;
}

else if (mm == “May”)
{
mm= “05”;
}

else if (mm == “Jun”)
{
mm= “06”;
}

else if (mm == “Jul”)
{
mm= “07”;
}

else if (mm == “Aug”)
{
mm= “08”;
}

else if (mm == “Sep”)
{
mm= “09”;
}

else if (mm == “Oct”)
{
mm= “10”;
}

else if (mm == “Nov”)
{
mm= “11”;
}

else if (mm == “Dec”)
{
mm= “12”;
}
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++

var date = mm+”/”+dd+”/”+yy;

var timestam_1 = Date.parse(date);
var timestam= timestam_1+86400000; //86400000 added to get correct timezone output from Date.parse
var time4 = new Date(timestam);
var Weeko = time4.getDay();
var dd2 = time4.getDate();
var mm2 = time4.getMonth();
var flag_y=arr[i][1];
var ahref_title=”Click here for full story”;
if(arr[i][2]) {
var url=arr[i][2];
var flag_date='{“x”:’+timestam+’, “title”:”  “,”text”:”Click here for Story!”}’;

flagAr[csvgen_counter].push(flag_date);
}
var yy2 = time4.getFullYear();
var yy3 = yy2+””;
var yy4= yy3.substring(2,4);
//++++++++++++++++++++++++this for days conversion++++++++++++++++++++++++++++
if (Weeko==1)
{
Weeko = “Mon”;
}

else if (Weeko==2)
{
Weeko = “Tue”;
}

else if (Weeko==3)
{
Weeko = “Wed”;
}

else if (Weeko==4)
{
Weeko = “Thu”;
}

else if (Weeko==5)
{
Weeko = “Fri”;
}

else if (Weeko==6)
{
Weeko = “Sat”;
}

else if (Weeko==0)
{
Weeko = “Sun”;
}

//+++++++++++++++++++++++this is for month conversion+++++

if (mm2==0)
{
mm2 = “Jan”;
}

else if (mm2==1)
{
mm2 = “Feb”;
}

else if (mm2==2)
{
mm2 = “Mar”;
}

else if (mm2==3)
{
mm2 = “Apr”;
}

else if (mm2==4)
{
mm2 = “May”;
}

else if (mm2==5)
{
mm2 = “Jun”;
}

else if (mm2==6)
{
mm2 = “Jul”;
}

else if (mm2==7)
{
mm2 = “Aug”;
}

else if (mm2==8)
{
mm2 = “Sep”;
}

else if (mm2==9)
{
mm2 = “Oct”;
}

else if (mm2==10)
{
mm2 = “Nov”;
}

else if (mm2==11)
{
mm2 = “Dec”;
}
//++++++++++++++++++++++++++++++++++++++++

//weekly
if ( timestamvar == timestamweek)
{
fomat2=dd2+”-“+mm2+”-“+yy4;
padding_value=timestamweek;
range_selector=2;
}

// Daily
else if ( timestamvar = timestamyear)
{
fomat2=mm2+”-“+yy4;
padding_value=timestamyear;
range_selector=3;
}

//monthly
else if ((timestamvar <= timestammonth30)&&(timestamvar = timestamquarterly)
{
fomat2=mm2+”-“+yy4;
padding_value=timestamquarterly;
range_selector=3;
}

else
{
fomat2=dd2+”-“+mm2+”-“+yy4;
padding_value=timestamday;
range_selector=3;
}

arr[i][0]= fomat2;
var decpad;
decpad = parseFloat(arr[i][1]);
arr[i][1] = decpad;

if(i==(arr.length-1))
{

// Functionality to get the last value

var xvalu=dd2+”-“+mm2+”-“+yy4;
var yvalu= String(arr[i][1]);
var xyvalu=”Latest value at “+xvalu+” is “+yvalu;
updt=”Updated on “+xvalu;
}

tempAr.push(timestam);
if(!arr[i][1])
{
arr[i][1]=null;
}
yaxisAr[csvgen_counter].push(arr[i][1]);
// tempAr1.push(timestam);
// tempAr2.push(tempAr1);
tempAr.push(arr[i][1]);
last_val=timestam;
finalAr[csvgen_counter].push(tempAr);
}
xpad=last_val+padding_value; //*****************to end up graph early//////
if(arr[i]== “”)
{
vi=arr.length-i;
arr.length=arr.length-vi;
i=arr.length-1;
fomat = replic;

var k=0;

do {
k++;
} while(fomat.charAt(k)!=”-“)
var k1 =k;

do {
k++;
} while(fomat.charAt(k)!=”-“)
var k2=k;

do {
k++;
} while(k<fomat.length)
var k3=k;

var dd= fomat.substring(0,k1);
var mm = fomat.substring(k1+1,k2);
var yy = "20"+fomat.substring(k2+1,k3+1);

// conversion of months into numerical form

//+++++++++++++++++++++++++++++++++++
if (mm == "Jan")
{
mm= "01";
}
else if (mm == "Feb")
{
mm= "02";
}

else if (mm == "Mar")
{
mm= "03";
}

else if (mm == "Apr")
{
mm= "04";
}

else if (mm == "May")
{
mm= "05";
}

else if (mm == "Jun")
{
mm= "06";
}

else if (mm == "Jul")
{
mm= "07";
}

else if (mm == "Aug")
{
mm= "08";
}

else if (mm == "Sep")
{
mm= "09";
}

else if (mm == "Oct")
{
mm= "10";
}

else if (mm == "Nov")
{
mm= "11";
}

else if (mm == "Dec")
{
mm= "12";
}
// +++++++++++++++++++++++++++++++++++++++++++++++++++++++

var date = mm+"/"+dd+"/"+yy;
//here flagAr may be
var timestam = Date.parse(date);
var time4 = new Date(timestam);
var Weeko = time4.getDay();
var dd2 = time4.getDate();
var mm2 = time4.getMonth();

var yy2 = time4.getFullYear();
var yy3 = yy2+"";
var yy4= yy3.substring(2,4);
//++++++++++++++++++++++++this for days conversion++++++++++++++++++++++++++++
if (Weeko==1)
{
Weeko = "Mon";
}

else if (Weeko==2)
{
Weeko = "Tue";
}

else if (Weeko==3)
{
Weeko = "Wed";
}

else if (Weeko==4)
{
Weeko = "Thu";
}

else if (Weeko==5)
{
Weeko = "Fri";
}

else if (Weeko==6)
{
Weeko = "Sat";
}

else if (Weeko==0)
{
Weeko = "Sun";
}

//+++++++++++++++++++++++this is for month conversion+++++

if (mm2==0)
{
mm2 = "Jan";
}

else if (mm2==1)
{
mm2 = "Feb";
}

else if (mm2==2)
{
mm2 = "Mar";
}

else if (mm2==3)
{
mm2 = "Apr";
}

else if (mm2==4)
{
mm2 = "May";
}

else if (mm2==5)
{
mm2 = "Jun";
}

else if (mm2==6)
{
mm2 = "Jul";
}

else if (mm2==7)
{
mm2 = "Aug";
}

else if (mm2==8)
{
mm2 = "Sep";
}

else if (mm2==9)
{
mm2 = "Oct";
}

else if (mm2==10)
{
mm2 = "Nov";
}

else if (mm2==11)
{
mm2 = "Dec";
}
//++++++++++++++++++++++++++++++++++++++++

//weekly
if ( timestamvar == timestamweek)
{
fomat2=dd2+"-"+mm2+"-"+yy4;
}

// Daily
else if ( timestamvar = timestamyear)
{
fomat2=mm2+”-“+yy4;
}

//monthly
else if ((timestamvar <= timestammonth30)&&(timestamvar = timestamquarterly)
{
fomat2=mm2+”-“+yy4;
}

arr[i][0]= fomat2;
var decpad;

decpad = parseFloat(arr[i][1]);
//arr[i][1] = roundVal(decpad);
arr[i][1] = decpad;
if(i==(arr.length-1))
{

var xvalu=dd2+”-“+mm2+”-“+yy4;
var yvalu= String(arr[i][1]);
var xyvalu=”Latest value at “+xvalu+” is “+yvalu;
updt=”Updated on “+xvalu;
}
}

}
}

//other required functions

//chart configuration starts here

function getXMLHttpRequest(file) {

//var arrSignatures = [“MSXML2.XMLHTTP.5.0”, “MSXML2.XMLHTTP.4.0″,
//”MSXML2.XMLHTTP.3.0”, “MSXML2.XMLHTTP”,
//”Microsoft.XMLHTTP”];

//for (var i=0; i < arrSignatures.length; i++) {

try
{
var xmlhttp = new window.XMLHttpRequest();
xmlhttp.open("POST",file,false);
return xmlhttp;
}
catch(e)
{
error=e.message;
}

//}
throw new Error("MSXML is not installed on your system.");
}

function readCSV(locfile) {
// load a whole csv file, and then split it line by line
var req = new getXMLHttpRequest(locfile);
//req.open("POST",locfile,false);
req.send("");
return req.responseText.split(/n/g);
}

function parseLineCSV(lineCSV) {
// parse csv line by line into array
var CSV = new Array();

lineCSV = lineCSV.replace(/,/g," ,");

lineCSV = lineCSV.split(/,/g);

// This is continuing of 'split' issue in IE
// remove all trailing space in each field
for (var i=0;i<lineCSV.length;i++) {
lineCSV[i] = lineCSV[i].replace(/s*$/g,"");
}

lineCSV[lineCSV.length-1]=lineCSV[lineCSV.length-1].replace(/^s*|s*$/g,"");
var fstart = -1;

for (var i=0;i=0) {
for (var j=fstart+1;j<=i;j++) {
lineCSV[fstart]=lineCSV[fstart]+","+lineCSV[j];
lineCSV[j]="-DELETED-";

}
fstart=-1;
}
}
fstart = (lineCSV[i].match(/^"/)) ? i : fstart;
}

var j=0;

for (var i=0;i<lineCSV.length;i++) {
if (lineCSV[i]!="-DELETED-") {
CSV[j] = lineCSV[i];
j++;
}

}

return CSV;
}

function roundVal(val_num){
var dec = 2;
var result = Math.round(val_num*Math.pow(10,dec))/Math.pow(10,dec);
return result;
}

function setdecimalpoints(deca)
{
var deca1= deca;
var deca2= parseInt(deca);
if((deca1-deca2)!=0)
{
return 2;
}
else
{
return 0;
}
}
for(i=0;i

Charts loading…
Charts loading…
Charts loading…
Charts loading…
Charts loading…
Charts loading…
Charts loading…

—————————–

Ian Dobbs is a currency analyst with Direct FX You can contact him here »