Advertisement
If you have a new account but are having problems posting or verifying your account, please email us on hello@boards.ie for help. Thanks :)
Hello all! Please ensure that you are posting a new thread or question in the appropriate forum. The Feedback forum is overwhelmed with questions that are having to be moved elsewhere. If you need help to verify your account contact hello@boards.ie
Hi there,
There is an issue with role permissions that is being worked on at the moment.
If you are having trouble with access or permissions on regional forums please post here to get access: https://www.boards.ie/discussion/2058365403/you-do-not-have-permission-for-that#latest

Even distribution of percentages of a list to use each uniquely

  • 08-01-2014 1:16pm
    #1
    Registered Users, Registered Users 2 Posts: 5,660 ✭✭✭


    Issue im having to get coverage to do unique actions to sublists of a list

    We use an offset so that the start point is unique in each sublist. Example data as follows.

    Doing action A to 30% of nodes with offset 0
    Doing action B to 30% of nodes with offset 1
    Doing action C to 30% of nodes with offset 2
    Doing action D D to 10% of nodes with offset 3

    We have a list of 135 nodes.

    ...1% of this list is 1.35 nodes
    ...30% of this list is 40.5 nodes (we round up to 41)
    ...10% of this list is 13.5 nodes (we round up to 14)

    The gap between nodes is calculated as 100 / percentage so..

    30% means a gap of 3 between each node in list
    10% means a gap of 14 between each node in list

    action A gives the node list as
    node1, node4, node7 etc
    action B gives the node list as
    node2, node5, node8 etc
    action C gives the node list as
    node3, node6, node9 etc
    action D gives the node list as
    node4, node18, node32 etc

    We would then be using the same nodes in more than 1 action.

    Maybe theres a better way to do this... ?


Advertisement