can i get analog output from pwm pin in xbee s2?

In series 2 only P0 (pin 6) is available.

No, the XBee ZB modules you are referring to do not support Analog to Digital and then Digital to Analog conversion.