Question: how to open uiautomatorviewer in android studio?
Answer: Launch the target app on a physical device. Connect the device to your development machine. Open a terminal window and navigate to the <android-sdk>/tools/ directory. Run the tool with this command: $ uiautomatorviewer.