fix: problem with the load_table method#3745
Conversation
|
Thanks for opening a Pull Request. If you want to perform a review write a comment saying: @ansys-reviewer-bot review |
for more information, see https://pre-commit.ci
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #3745 +/- ##
==========================================
- Coverage 88.27% 88.25% -0.03%
==========================================
Files 187 187
Lines 14705 14708 +3
==========================================
- Hits 12981 12980 -1
- Misses 1724 1728 +4 |
germa89
left a comment
There was a problem hiding this comment.
thank you @kmkoshy a lot for doing this PR. I really appreciate the time you took for this.
Overall it is great, good docs, good tests,... no big suggestions. Just styling changes.
(By the way, I did add some tests which do not add anything on top your PR, but I did them for myself to understand how the tables works, so I thought it will be good idea to include them in the test set)
Again, great work. Thank you a lot!
Co-authored-by: German <28149841+germa89@users.noreply.github.com>
|
Thank you @germa89 for the review and suggestion. |
Description
Please provide a brief description of the changes made in this pull request.
mapdl behavior of *TREAD when column number is more than 2 is that it takes the first row as column header.
There are two possible scenarios :
fix attempted by introducing a keyword arg
col_headerto handle case with col_header.when col_header=True do not go through the logic of copying the first row again. (which is why we see the issue in 3305).
update dim accordingly.
from #3305 updating the load_table cmd with the keyword arg
col_header:True should fix the issue.mapdl.load_table('acc_data', acceleration_data, 'time',col_header=True)
Issue linked
Please mention the issue number or describe the problem this pull request addresses.
#3305
Checklist
draftif it is not ready to be reviewed yet.feat: adding new MAPDL command)