Plotly R sankey plot-隐藏单个悬停标签上的值

Plotly R sankey plot-隐藏单个悬停标签上的值,plot,hover,label,plotly,Plot,Hover,Label,Plotly,我有一个非常标准的sankey绘图,使用r中的plotly(Ploty)创建。是否有方法仅显示悬停标签中的某些值。我想显示所有链接,但由于数据保密性限制,我想隐藏其中少数链接的特定值 谢谢 fig <- plot_ly( type = "sankey", domain = list(x = c(0,1),y = c(0,1)), arrangement = "freeform", orientation = "h&quo

我有一个非常标准的sankey绘图,使用r中的plotly(Ploty)创建。是否有方法仅显示悬停标签中的某些值。我想显示所有链接,但由于数据保密性限制,我想隐藏其中少数链接的特定值

谢谢

fig <- plot_ly(
  type = "sankey",
  domain = list(x =  c(0,1),y =  c(0,1)),
  arrangement = "freeform",
  orientation = "h",
  valueformat = ".1f",
  #valuesuffix = "TWh",key 
  
  node = list(
    label = lab,
    x=posx,
    y=posy,
    color = col,
    pad = 10,
    thickness = 15,
    line = list(color = "black",width = 0.5)
  ),
  
  link = list(
    source = sum$source,
    target = sum$target,
    value  = sum$value,
    label  = sum$label,
    color  = sum$color
  )
) 
fig <- fig %>% layout(
  #title = "", font = list(size = 10),
  xaxis = list(showgrid = F, zeroline = F),
  yaxis = list(showgrid = F, zeroline = F)
)

fig