Step 5 - The next step is to setup the PWM6 module. Click on PWM6 under Project Resources.
The PWM6 setup will appear in the center of the MPLAB X screen. This requires a few setup selections.
Check the Enable PWM box
Select Timer2 from the Select a Timer drop-down menu.
Set the Duty Cycle to '50%'.
The result should look like this:
Step 6 - Open the Pin Manager: Grid View tab and then click on the PWM6 Output pin row in the RA4 column to select the blue lock. It should turn green. This will output the PWM signal to the RA4 pin connected to the D2 LED. It should look like the picture when completed: