An updated version of my Dynamo nodes package (rev.2017.5.19) is available at Dynamopackages.com. It's now equipped with Railing.CountBalusters custom node, which is based on the "Railing.BalusterCount" node from Rhythm package. I had to rebuild the original node to get rid of the 'false positives' in resulting number of balusters. Below you can see the difference between these two nodes, and the numbers they show as an output:
I've tested the tweaked node on different railing types: horizontal, sloped, and curved, so it should work correctly.
Please note that Railing.CountBalusters can handle only one railing instance at a time, so do not try to feed a list of multiple elements into it.
I'm going to write a dedicated post to describe my node, and why did I have to rebuild it. In the meantime, you can download an updated package here: Zhukoven.com_(Rev.2017.5.19) or via default Package Manager in Dynamo.
(UPDATE): here's the link to the dedicated post about Revit railings: Count railing balusters in Revit with Dynamo