Below you can see the front-view size comparison of the Canon RP and Pentax K-3. The Canon RP is 15 mm shorter and 7 mm thinner than the Pentax K-3 but it is also 2 mm wider.
The chart below depicts how two cameras compare with average dimensions of the cameras in their class.