Forum Discussion
Custom Visual Performance is lacking?
Hi jnat5,
R visuals are delegated to an external interpreter by the visuals layer, which is web-based - this is either your local interpreter (if using Desktop) or an interpreter in the Service hosted by MS (if published).
There is a 'round trip' / 'cold start' cost often associated with this as it is managed over HTTP and processed into a static image (or HTML if using RHTML in the custom visuals SDK) before being rendered in the DOM of the developer visual as such.
You will indeed get much better performance if you can work directly with the TypeScript SDKs as this is 'native' to Power BI.
I got into custom visual development in a similar way - started with R and found this performance bottleneck somewhat frustrating, so now I do all dev in TypeScript. Highly optimised code can be very performant.
If you don't want to go full web dev, and can manage with frameworks like Vega-Lite, I'm working on a visual called Deneb, which may bridge this gap.
Regards,
Daniel