Skip to content

How do you handle multi-layer header CSV file's series index ? #1467

Answered by aborruso
coolbq asked this question in Q&A

You must be logged in to vote

I'm not sure I understand, but I'll try to give you an answer.

Running <sample.tsv tail -n +6 >body.tsv, you save the data.
Running <sample.tsv head -n 5 >header.tsv you save the header.

The body will be in this way

If it is useful for you, you can transpose the header, coupling Miller with qsv.

<header.tsv mlr --csv remove-empty-columns | qsv transpose >transposed_header.tsv

Replies: 2 comments 3 replies

You must be logged in to vote
0 replies

You must be logged in to vote
3 replies
@coolbq

@aborruso

Answer selected by coolbq
@coolbq

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants