{"id":1311,"date":"2018-05-07T19:02:03","date_gmt":"2018-05-08T02:02:03","guid":{"rendered":"https:\/\/officedevblogs.wpengine.com\/?p=1311"},"modified":"2023-08-22T16:13:59","modified_gmt":"2023-08-22T23:13:59","slug":"azure-machine-learning-javascript-custom-functions-and-power-bi-custom-visuals-further-expand-developers-capabilities-with-excel","status":"publish","type":"post","link":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/azure-machine-learning-javascript-custom-functions-and-power-bi-custom-visuals-further-expand-developers-capabilities-with-excel\/","title":{"rendered":"Azure Machine Learning, JavaScript Custom Functions, and Power BI Custom Visuals Further Expand Developers Capabilities with Excel"},"content":{"rendered":"<p>Today at Build, we announced a powerful set of capabilities to the Excel platform, offering developers, data scientists, and power users more opportunities to better work with data. Developers and data scientists can now to execute custom functions locally in JavaScript or with Microsoft Azure Machine Learning services to\u00a0create their own powerful additions to Excel&#8217;s catalog of formulas.\u00a0Excel has enabled an out of the box bridge between business users and data science teams, to accelerate the digital transformation of businesses.\u00a0With new support for Power BI Custom Visuals,\u00a0developers will be able to\u00a0build new kinds of data visualizations in Excel \u2014 giving users a much more diverse charting experience, right in Excel. Finally, Excel will integrate with Flow, allowing users sending data directly from a spreadsheet to a range of services. Read on to learn more.<\/p>\n<h3>Machine Learning and JavaScript custom functions for developers and data scientists.<\/h3>\n<p>Custom functions (similar to &#8220;user-defined functions&#8221; or &#8220;UDFs&#8221;) are ways for developers to extend Excel&#8217;s built-in set of formula functions. Users can create their own functions locally in JavaScript or with Machine Learning teams earning services. They can see and run these functions in Excel alongside built-in functions like =SUM or =VLOOKUP. The best part is that those same functions will work everywhere add-ins do: on PC, Mac, and iPad, and in Excel Online.<\/p>\n<p><strong>JavaScript custom functions<\/strong><\/p>\n<p>Office developers have been wanting to write JavaScript custom functions for many reasons, such as:<\/p>\n<ul>\n<li>Calculate math operations, like whether a number is prime.<\/li>\n<li>Bring information from the web, like a bank account balance.<\/li>\n<li>Stream live data, like a stock price.<\/li>\n<\/ul>\n<p>Starting today, developers can build JavaScript custom functions at\u00a0<a href=\"https:\/\/aka.ms\/customfunctions\">https:\/\/aka.ms\/customfunctions<\/a>. They&#8217;re already enabled for Windows, Mac, and Excel Online.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/devofficecdn.azureedge.net\/media\/Default\/Blog%20Images\/customfunction.gif\" alt=\"Using a custom function in Excel\" width=\"583\" height=\"385\" \/><\/p>\n<p><em>Using a custom function in Excel<\/em><\/p>\n<p><strong>Machine Learning functions<\/strong><\/p>\n<p>Machine Learning functions can be created by AI developers, including data scientists and other experts. The functions are each based on a service that calculates or predicts values with a machine learning model. Once the model is deployed, the creators can enable it for anyone they choose. Within a company, administrators can configure who has access to which proprietary functions. Then, every time someone wants to run the function, they simply type in a cell, just like for any other Excel function. The function calls a live web service on the company\u2019s Azure subscription and returns the result asynchronously.<\/p>\n<p>There are many useful function types developers can enable with Machine Learning, such as:<\/p>\n<ul>\n<li>Smart forecasting, like predicting the future revenue trend at a company based on time series data in Excel.<\/li>\n<li>Classification problems for many Excel rows, like fraud detection from credit card transactions.<\/li>\n<li>Any custom Python code, like a function to analyze text in cells.<\/li>\n<\/ul>\n<p>&nbsp;<\/p>\n<h3>Power BI Custom Visuals for developers and power users.<\/h3>\n<p>Custom Visuals enable developers to extend the existing chart set in Excel and Power BI using standard Open Source technologies, like JavaScript and D3. If you\u2019ve built a cool visualization based on web technologies, and you\u2019re wondering how to reach the millions of Excel users that insert charts daily, this feature is for you. Or, if you\u2019re a Power BI developer who has already built custom visuals, your visual can now reach a much wider audience. That\u2019s because the same technology powers the Custom Visuals feature in both products. You can write your visual once, and have it work in both places.<\/p>\n<p>Here are some examples of Custom Visuals that exist today:<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/devofficecdn.azureedge.net\/media\/Default\/Blog%20Images\/Image%202.png\" alt=\"Examples from rich third-party ecosystem of Power BI Custom Visuals in Excel.\" width=\"740\" height=\"325\" \/><\/p>\n<p><em>Examples from rich third-party ecosystem of Power BI Custom Visuals in Excel.<\/em><\/p>\n<p>Custom Visuals provide several key benefits that make them an appealing choice for data visualization development in Excel including:<\/p>\n<ul>\n<li><strong>Intuitive insertion experience:\u00a0<\/strong>Custom Visuals live alongside existing charts in Excel. There are new entry points in the Chart ribbon, as well as a dedicated tab in the Insert Chart Insert dialog. The result is a familiar experience for users.<\/li>\n<li><strong>Tailored Office Store experience<\/strong>: Like Office add-Ins, Custom Visuals can be published to the\u00a0<a href=\"http:\/\/store.office.com\/\">Microsoft Store<\/a>. Exploring new charting options in the store is a one-click tailored experience that lets users navigate directly to a set of Custom Visuals.<\/li>\n<li><strong>Intuitive UI controls:\u00a0<\/strong>Excel provides common UI helping users connect visuals to their spreadsheet data, as well as configure properties. Providing this UI gives users consistent experience across all visuals. And having ready-made controls saves development time, allowing developers to stay focused on the visual content itself.<\/li>\n<li><strong>Enterprise ready<\/strong>: Not all Custom Visuals are meant for the public Microsoft Store. Enterprise developers can continue building visuals in-house for their specific line-of-business needs (such as, for example, an airline company building a custom \u201cairplane visual\u201d for displaying information about seat booking). Office 365 admins will have the ability to deploy visuals in the same way that Office add-ins are deployed, and those new chart types will appear in the Insert Chart Insert dialog automatically without any additional work needed by users.<\/li>\n<\/ul>\n<p><img decoding=\"async\" src=\"https:\/\/devofficecdn.azureedge.net\/media\/Default\/Blog%20Images\/Image%203.png\" alt=\"Customs Visuals live with other Excel charts. Visuals acquired from the store, or those deployed by an Office 365 administrator, will automatically appear here. The store for Custom Visuals can also be launched from here Note, these visuals are just examples of the types of visuals in the Office App Store.\" width=\"740\" height=\"847\" \/><\/p>\n<p><em>Customs Visuals live with other Excel charts. Visuals acquired from the store, or those deployed by an Office 365 administrator, will automatically appear here. The store for Custom Visuals can also be launched from here\u00a0 Note, these visuals are just examples of the types of visuals in the Office App Store.<\/em><\/p>\n<p><em>\u00a0<img decoding=\"async\" src=\"https:\/\/devofficecdn.azureedge.net\/media\/Default\/Blog%20Images\/Image%204.png\" alt=\"Excel provides a tailored view of the Office App Store that lets you focus on just the Custom Visuals. Note, the example visuals shown here are existing Custom Visuals for Power BI and may not all be available in Excel.\" width=\"740\" height=\"841\" \/>\u00a0<\/em><\/p>\n<p><em>Excel provides a tailored view of the Office App Store that lets you focus on just the Custom Visuals. Note, the example visuals shown here are existing Custom Visuals for Power BI and may not all be available in Excel.<\/em><\/p>\n<p><em>\u00a0<img decoding=\"async\" src=\"https:\/\/devofficecdn.azureedge.net\/media\/Default\/Blog%20Images\/Image%205.png\" alt=\"The task pane helps users connect their Custom Visuals to spreadsheet data, as well as configure settings on the visual. The same task pane appears for all visuals, making the user experience easy and familiar for users across all visuals.\" width=\"740\" height=\"382\" \/>\u00a0<\/em><\/p>\n<p><em>The task pane helps users connect their Custom Visuals to spreadsheet data, as well as configure settings on the visual.\u00a0 The same task pane appears for all visuals, making the user experience easy and familiar for users across all visuals.<\/em><\/p>\n<p>The combination of a more tightly integrated experience together with a customized store and a consistent UX, will give data visualization developers maximum reach to their audience. For more information, visit\u00a0<a href=\"https:\/\/github.com\/Microsoft\/PowerBI-Visuals\/\">API documentation for Custom Visuals<\/a>\u00a0to get started today writing visuals for Power BI. Visit the\u00a0<a href=\"https:\/\/appsource.microsoft.com\/en-us\/marketplace\/apps?product=power-bi-visuals&amp;page=1&amp;src=office\">Custom Visuals Store<\/a>\u00a0to see what kinds of visuals are currently offered.<\/p>\n<p>&nbsp;<\/p>\n<h3>Flow integration with Excel<\/h3>\n<p>With this integration, users can create, manage, and most importantly run automated workflows on Excel tabular data. Via Flow, users will be able to send data from their spreadsheets hosted in SharePoint and OneDrive for Business to a wide range of services such as Teams, Dynamics 365, Visual Studio Online, Twitter, etc. The integration will first be shipped as an add-in in the Office Store and will become an in-the-box component later this year.<\/p>\n<p><img decoding=\"async\" src=\"https:\/\/devofficecdn.azureedge.net\/media\/Default\/Build\/New%20image.png\" alt=\"Flow integration with Excel\" width=\"740\" height=\"615\" \/><\/p>\n<p>These new capabilities are the result of continuous innovation to make Excel a more flexible and intuitive data analysis tool and expand developer opportunities.\u00a0To stay connected to Excel and its community, read\u00a0<a href=\"https:\/\/techcommunity.microsoft.com\/t5\/Excel-Blog\/bg-p\/ExcelBlog\">Excel blog posts<\/a>, and send us ideas and suggestions for the next version of Excel through our\u00a0<a href=\"https:\/\/excel.uservoice.com\/\">UserVoice<\/a>. You can also follow Excel on\u00a0<a href=\"https:\/\/www.facebook.com\/microsoftexcel\/\">Facebook<\/a>\u00a0and\u00a0<a href=\"https:\/\/twitter.com\/msexcel?ref_src=twsrc%5egoogle%7ctwcamp%5eserp%7ctwgr%5eauthor\">Twitter<\/a>.<\/p>\n<p><strong>Availability<\/strong><\/p>\n<p><em><strong>JS custom functions<\/strong><\/em><em>\u00a0for Excel is available now in Developer Preview to Office 365 subscribers enrolled in the\u00a0<\/em><a href=\"https:\/\/products.office.com\/en-us\/office-insider?tab=Windows-Desktop\">Office Insiders program<\/a><em>.\u00a0<strong>Azure Machine Learning functions and Power BI Custom Visuals\u00a0<\/strong>will be rolling out in preview soon\u2014stay posted\u00a0<\/em><a href=\"https:\/\/twitter.com\/officedev\">@OfficeDev<\/a><\/p>\n<p>Interested developers can\u00a0<a href=\"http:\/\/aka.ms\/xlcvdev\">sign up here<\/a>\u00a0to get updates as custom visuals becomes available.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Today at Build, we announced a powerful set of capabilities to the Excel platform, offering developers, data scientists, and power users more opportunities to better work with data. Developers and data scientists can now to execute custom functions locally in JavaScript or with Microsoft Azure Machine Learning services to\u00a0create their own powerful additions to Excel&#8217;s catalog of formulas.\u00a0<\/p>\n","protected":false},"author":69076,"featured_media":25159,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"footnotes":""},"categories":[11,20],"tags":[18],"class_list":["post-1311","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-office-add-ins","category-power-platform","tag-excel"],"acf":[],"blog_post_summary":"<p>Today at Build, we announced a powerful set of capabilities to the Excel platform, offering developers, data scientists, and power users more opportunities to better work with data. Developers and data scientists can now to execute custom functions locally in JavaScript or with Microsoft Azure Machine Learning services to\u00a0create their own powerful additions to Excel&#8217;s catalog of formulas.\u00a0<\/p>\n","_links":{"self":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/1311","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/users\/69076"}],"replies":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/comments?post=1311"}],"version-history":[{"count":0,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/posts\/1311\/revisions"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media\/25159"}],"wp:attachment":[{"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/media?parent=1311"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/categories?post=1311"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/devblogs.microsoft.com\/microsoft365dev\/wp-json\/wp\/v2\/tags?post=1311"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}