New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add fwf_cols function #616
Merged
Merged
Commits on Feb 18, 2017
-
This adds a helper function `fwf_cols` that is a more intuitive way of specifying fixed width column start and end points. While `fwf_positions` requires three vectors for start, end, and names, `fwf_cols` accepts a named list of length-2 vectors of the column start and end positions.
-
Commits on Feb 20, 2017
Commits on Feb 23, 2017
-
This adds a helper function `fwf_cols` that is a more intuitive way of specifying fixed width column start and end points. While `fwf_positions` requires three vectors for start, end, and names, `fwf_cols` accepts a named list of length-2 vectors of the column start and end positions.
-
-
This adds a helper function `fwf_cols` that is a more intuitive way of specifying fixed width column start and end points. While `fwf_positions` requires three vectors for start, end, and names, `fwf_cols` accepts a named list of length-2 vectors of the column start and end positions.
-
Updates to fwf_* column position functions
- read_fwf arg col_positions will check for column names and whether the data frame is widths or a start/end data frame. - rewrite fwf_cols to accept named args of length 1 or 2. This makes it more concise. Also accept a data frame as the first argument - More checks for argument validity - Use tibbles instead of lists where appropriate Some tests failing. Still need to debug.
Commits on Feb 24, 2017
Commits on Feb 25, 2017
-
Move fwf_col_names function lower in file. See tidyverse#616
-
Add widths form of fwf_cols to documentation See tidyverse#616
-
This is too complicated; since we have fwf_cols, don't worry about list inputs. See tidyverse#616
-
Remove a try() call since, the preference is for errors to bubble up to users. See tidyverse#616
-
This seems too flexible, so I'll change it to just use ... See tidyverse#616
-
- removed tests that failed after removing features in fwf_cols in previous commits - remove test that failed because fwf_positions changes columns to numeric
-
Revert this section in read_fwf since it is unnecessary to handle data list objects with the availability of fwf_cols See tidyverse#616
-
convert numeric constants in fwf functions
Convert some numeric constants to integer constants so that addition/subtraction does not coerce columns to numeric if they were integer. This is not a big deal, but since the positions represent integers anyways, it might as well keep them as such if they are already specified as such.
-
-
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.