Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!To celebrate FabCon Vienna, we are offering 50% off select exams. Ends October 3rd. Request your discount now.
Are "png" and "html" the only valid values for "scriptOutputType"? The capabilities.json schema just says a string, and when I tried changing this to "json" or "xml" I got errors from the developer visual saying that the script is not returning an image, even when visual.ts doesn't actually refer to the dataview at all (e.g. if the visual is only supposed to display "hello world" text or something like that). I'm not sure whether this is because of a problem with my R/TS code, or because the behaviour is different when the visual is expecting an output from R, or something else entirely. I've been through the docs and the repos of several other R-powered custom visuals, but have only been able to find code examples where the result of the R script is returned in html or png format.
Ideally I'd like the R portion of the code to handle the calculations but not the plotting, so that I can use the existing powerbi-visuals-utils to handle all the stuff relating to display, interactivity, etc. I want to maintain as much consistency of appearance and functionality with the native visuals as possible.
Has anyone come across R-powered custom visuals where the R code doesn't do the plotting? Am I missing something vital, or is what I want to do just not supported?
Hi @blep,
I don't think you can do custom with the custom visual return type. Most of them have been defined in the package function structure.
If you want to do more integration with R scripts, I'd like to suggest you switch to r visual and it will share more permission to use R script library operations.
Notice: custom visuals are different from R visual, it obviously contains limits to use different functions and interfaces processing backend functions.
Regards,
Xiaoxin Sheng