I've not personally tried this, but I believe you can save analytics workbooks within the UI in NetSuite and then load and query that kind of similarly to a stored procedure. This isn't written as SuiteQL and is more of a UI thing though so it might not be exactly what you're looking for. Check out N/query load API.