# `GSLayer indexPathOfNodeAtY:actualPosition:`

*Instance Method*

Returns the index path of an on-curve node near the given y position.

## Declaration

```objc
- (NSIndexPath *) indexPathOfNodeAtY:(CGFloat) Y actualPosition:(NSPoint *) pos;
```

```python
indexPathOfNodeAtY_actualPosition_(Y: float, pos: NSPoint) -> NSIndexPath
```

## Return Value

The node index path, or `nil` if no matching node or hint position is found.

## Discussion

The actual matched position is written to `pos` when provided.

## See Also

### Node Hit Testing

- [`GSLayer nodeAtPoint:excludeNode:ignoreLocked:tolerance:`](/Core/GlyphsCore/GSLayer/nodeAtPoint:excludeNode:ignoreLocked:tolerance:) — Returns the nearest node to a point, excluding one node.
- [`GSLayer nodeAtPoint:excludeNodes:traverseComponents:ignoreLocked:tolerance:`](/Core/GlyphsCore/GSLayer/nodeAtPoint:excludeNodes:traverseComponents:ignoreLocked:tolerance:) — Returns the nearest node to a point, excluding a set of objects.
- [`GSLayer indexPathOfNodeAtX:actualPosition:`](/Core/GlyphsCore/GSLayer/indexPathOfNodeAtX:actualPosition:) — Returns the index path of an on-curve node near the given x position.

