For the two illustrated variations,
A = GRanges("A", IRanges(c(100, 200, 300), c(180, 220, 500)))
B = GRanges("A", IRanges(c(110, 320, 400), c(130, 350, 460)))
we have
> setdiff(A, B)
GRanges object with 6 ranges and 0 metadata columns:
seqnames ranges strand
<Rle> <IRanges> <Rle>
[1] A [100, 109] *
[2] A [131, 180] *
[3] A [200, 220] *
[4] A [300, 319] *
[5] A [351, 399] *
[6] A [461, 500] *
-------
seqinfo: 1 sequence from an unspecified genome; no seqlengths
Or the -A option
> A[!A %over% B]
GRanges object with 1 range and 0 metadata columns:
seqnames ranges strand
<Rle> <IRanges> <Rle>
[1] A [200, 220] *
-------
seqinfo: 1 sequence from an unspecified genome; no seqlengths
These are for GRanges; if you have a GRangesList then it might help to show an example of the structures you're working with; psetdiff()
might also be relevant.