One way of analyzing the statements is to look at a truth table. Let's make the following definitions:
A := "I am in New York"
B := "I am in America".
X := "I am in New York only if I am in America"
Y := "If I am in New York, then I am in America"
If both A and B are true, then X is true. We can write that as X(TT) = T. We have X(TF) = F (If you are in New York but not in America, then the statement "I am in New York only if I am in America" must be false). X(FT) = T and X(FF) = T; X makes a statement about what has to be true when you're in New York, so if you're not in New York, then X isn't telling you anything so it can't be proven wrong.
If you analyze Y, you'll find that all the values are the same:
X(TT) = Y(TT) = T
X(TF) = Y(TF) = F
X(FT) = Y(FT) = T
X(FF) = Y(FF) = T
Since no matter the truth values of A and B, X has the same truth value as Y, X and Y are equivalent; if you have two statements such that it's not possible for one to be true and the other false, then the two statements are saying essentially the same thing.
One thing to keep in mind is that in Formal Logic, statements of the form "If S1 then S2" are considered true any time S1 is false; that is, "If S1 then S2" is interpreted as meaning "Whenever S1 is true, S2 is also true". Because of this, "If S1 then S2" is equivalent to "Either S1 is false, or S2 is true" (if S1 is false, then the statement is automatically true, because it doesn't say anything about the situation of S1 being true). And "S1 only if S2 " is also equivalent to "Either S1 is false, or S2 is true".