The Texan, who will leave the Yamaha team at the end of the season to join the Ducati Junior Team, has endured a difficult year but he adapted best to the wet conditions to boost his confidence ahead of Sunday's race.
The 2009 Superbike world champion set a lap of two minutes 00.219 seconds in the afternoon to edge out Pedrosa's Repsol Honda by less than a tenth of a second.
Most of the frontrunners had elected to sit out the morning session but once further rain arrived they were all on track early in the afternoon session.
Pedrosa is desperate to get his title challenge back on track in Aragon after being punted out of the last race in Misano by Hector Barbera.
The Spaniard is now 38 points behind compatriot Lorenzo, but won their personal duel to claim second spot, with the Yamaha rider half a second adrift in third.
Nicky Hayden was fourth for Ducati with Andrea Dovizioso fifth on the Tech 3 Yamaha.
Stefan Bradl was again in the top six for the LCR Honda squad, while Britain's Cal Crutchlow was back in seventh.
Crutchlow was pleased with his pace, and felt he could have been higher up the charts but for a problem towards the end of the session.
"I am pleased with my pace in the full wet conditions as I was right near the top and confident I could have finished inside the top three," he said. "I had a small problem with the steering damper right at the end and without that I am sure I would have been much higher than seventh.
"We have to take another step tomorrow [Saturday] if the conditions are the same but I am confident I can be very competitive in the wet."
Valentino Rossi, fresh from his encouraging second place at Misano, was eighth with Karel Abraham and Alvaro Bautista rounding out the top 10.
Northern Ireland's Jonathan Rea continued his adaptation to MotoGP with 11th on the second Repsol Honda.