Are you using Map Viewer, or Map Viewer Classic? The analysis tools are at this time still only available in Map Viewer Classic.
If you are in Map Viewer Classic, and you are not seeing the 'Perform Analysis' button in the toolbar, there could be several reasons for this:
You are logged in to a public account instead of an organizational account
It is required for users to have an ArcGIS Online for Organizations account to use the analysis tools.
You do not have the required privileges to access the Perform Analysis tools
To perform analysis, the administrator of the organization must grant the user the following privileges:
The URL to the feature service is not a public URL
Analysis tools cannot be performed on map services that are internally facing; the feature service must be externally accessible. The URL to the service must be a public URL, and not only accessible behind a firewall. If a non-public map or feature service is used, an error message that the URL is not accessible is returned. Check out the help documentation for this information.
The organizational account does not have enough credit balance
It is also possible that your organizational account might not have sufficient credit balance to perform operations using the analysis tools. For best practices, ArcGIS Online has a set of tools in place to manage and monitor credit usage. Refer to the following blog post for more details: Five Strategies and Tools for Managing Credits in ArcGIS Online.
Please let me know if you have any further questions. Cheers,