This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def import_module(file_name): | |
"""Import the file (including optional relative or absolute path) into | |
a module namespace. | |
Args: | |
file_name - A string with the name of the file to load as a module. | |
Returns: | |
The module namespace. | |
""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
suppressMessages(library("gbm")) | |
suppressMessages(library("plotly")) | |
PlotInteraction <- function(model, interactingVariables) { | |
interactionEffect <- .ComputeInteractionEffect(model, interactingVariables) | |
.PlotInteractionSurface(interactionEffect, interactingVariables) | |
} | |
.PlotInteractionSurface <- function(interactionEffect, interactingVariables) { | |
xAxis <- .GetXAxis(interactionEffect) |