Peer Review History

Original SubmissionFebruary 13, 2022
Decision Letter - Rebecca Lee Smith, Editor

PONE-D-22-04434A machine learning approach using k – mode clustering and random forest classification to model groups of production parameters and bulk tank milk antibody status of two major internal parasites in dairy cowsPLOS ONE

Dear Dr. Oehm,

Thank you for submitting your manuscript to PLOS ONE. After careful consideration, we feel that it has merit but does not fully meet PLOS ONE’s publication criteria as it currently stands. Therefore, we invite you to submit a revised version of the manuscript that addresses the points raised during the review process.

Please submit your revised manuscript by Jun 06 2022 11:59PM. If you will need more time than this to complete your revisions, please reply to this message or contact the journal office at plosone@plos.org. When you're ready to submit your revision, log on to https://www.editorialmanager.com/pone/ and select the 'Submissions Needing Revision' folder to locate your manuscript file.

Please include the following items when submitting your revised manuscript:

  • A rebuttal letter that responds to each point raised by the academic editor and reviewer(s). You should upload this letter as a separate file labeled 'Response to Reviewers'.
  • A marked-up copy of your manuscript that highlights changes made to the original version. You should upload this as a separate file labeled 'Revised Manuscript with Track Changes'.
  • An unmarked version of your revised paper without tracked changes. You should upload this as a separate file labeled 'Manuscript'.

If you would like to make changes to your financial disclosure, please include your updated statement in your cover letter. Guidelines for resubmitting your figure files are available below the reviewer comments at the end of this letter.

If applicable, we recommend that you deposit your laboratory protocols in protocols.io to enhance the reproducibility of your results. Protocols.io assigns your protocol its own identifier (DOI) so that it can be cited independently in the future. For instructions see: https://journals.plos.org/plosone/s/submission-guidelines#loc-laboratory-protocols. Additionally, PLOS ONE offers an option for publishing peer-reviewed Lab Protocol articles, which describe protocols hosted on protocols.io. Read more information on sharing protocols at https://plos.org/protocols?utm_medium=editorial-email&utm_source=authorletters&utm_campaign=protocols.

We look forward to receiving your revised manuscript.

Kind regards,

Rebecca Lee Smith, D.V.M., M.S., Ph.D.

Academic Editor

PLOS ONE

Journal Requirements:

When submitting your revision, we need you to address these additional requirements.

1. Please ensure that your manuscript meets PLOS ONE's style requirements, including those for file naming. The PLOS ONE style templates can be found at

https://journals.plos.org/plosone/s/file?id=wjVg/PLOSOne_formatting_sample_main_body.pdf  and

https://journals.plos.org/plosone/s/file?id=ba62/PLOSOne_formatting_sample_title_authors_affiliations.pdf

2. Thank you for stating the following financial disclosure:

“Farm visits and data collection in the context of the underlying cross-sectional study were financially supported by the German Federal Ministry of Food and Agriculture (BMEL) through the Federal Office for Agriculture and Food (BLE) grant number 2814HS008.”

Please state what role the funders took in the study.  If the funders had no role, please state: "The funders had no role in study design, data collection and analysis, decision to publish, or preparation of the manuscript."

If this statement is not correct you must amend it as needed.

Please include this amended Role of Funder statement in your cover letter; we will change the online submission form on your behalf.

Additional Editor Comments (if provided):

Please be certain to address all reviewer concerns, particularly as to terminology and full description of data.

[Note: HTML markup is below. Please do not edit.]

Reviewers' comments:

Reviewer's Responses to Questions

Comments to the Author

1. Is the manuscript technically sound, and do the data support the conclusions?

The manuscript must describe a technically sound piece of scientific research with data that supports the conclusions. Experiments must have been conducted rigorously, with appropriate controls, replication, and sample sizes. The conclusions must be drawn appropriately based on the data presented.

Reviewer #1: No

Reviewer #2: Yes

**********

2. Has the statistical analysis been performed appropriately and rigorously?

Reviewer #1: No

Reviewer #2: Yes

**********

3. Have the authors made all data underlying the findings in their manuscript fully available?

The PLOS Data policy requires authors to make all data underlying the findings described in their manuscript fully available without restriction, with rare exception (please refer to the Data Availability Statement in the manuscript PDF file). The data should be provided as part of the manuscript or its supporting information, or deposited to a public repository. For example, in addition to summary statistics, the data points behind means, medians and variance measures should be available. If there are restrictions on publicly sharing data—e.g. participant privacy or use of data from a third party—those must be specified.

Reviewer #1: No

Reviewer #2: Yes

**********

4. Is the manuscript presented in an intelligible fashion and written in standard English?

PLOS ONE does not copyedit accepted manuscripts, so the language in submitted articles must be clear, correct, and unambiguous. Any typographical or grammatical errors should be corrected at revision, so please note any specific errors here.

Reviewer #1: Yes

Reviewer #2: Yes

**********

5. Review Comments to the Author

Please use the space provided to explain your answers to the questions above. You may also include additional comments for the author, including concerns about dual publication, research ethics, or publication ethics. (Please upload your review as an attachment if it exceeds 20,000 characters)

Reviewer #1: In the title the authors write "k-mode clustering" but in the method section it states "K-medoids" without mentioning "k-mode"(line 207). It should be noted that these terms and the corresponding algorithms are very different.

title - What are these "groups of production parameters and bulk tank milk antibody status"? I don't see any groups of parameters reported. The groups should be of the farms according to the context.

line 67, This sentence is confusing. what is the difference between the terms "cluster" and "group" in this sentence. For clustering analyses, the cluster is the group.

line 191, "Missing values were excluded from" -> Farms with missing values were excluded

Line 192, "Apart from" could mean "except for" or " in addition to". Is antibody status in or not in the model? I think " in addition to" is better here.

line 213 "PAM replaces centroids with medoids"-> PAM replaces means with medoids

line 218 "Classification of Clusters by means of Random Forest". Clustering analyses is for unsupervised classification, I don't see why clusters need to be classified again. Besides, there are only 2 cluster reported (figure 1), how could these be classified again?

Reviewer #2: The manuscript describes a strong and novel work that used k-mode clustering to separate the internal features of the different diary farms and used random forest to analyze features that are important to the cluster separation. The authors used very rigorous statistical approaches in data acquisition, cleaning, aggregation, and analysis. The authors clearly demonstrated the methodology and results, and come to a well-supported conclusion that the antibody status of two major internal parasites in diary cows strongly affects the milk yield and nutrition content. The work thoroughly covered a vast number of farms over major diary production regions in Germany. The conclusion was also supported by relevant studies and field. In addition to the scientific insight that brings direct economical benefits, the manuscript demonstrated the feasibility of using un-supervised methods to perform non-biased analyze on the topic. Therefore, I strongly recommend publication of the work.

**********

6. PLOS authors have the option to publish the peer review history of their article (what does this mean?). If published, this will include your full peer review and any attached files.

If you choose “no”, your identity will remain anonymous but your review may still be made public.

Do you want your identity to be public for this peer review? For information about this choice, including consent withdrawal, please see our Privacy Policy.

Reviewer #1: No

Reviewer #2: Yes: Weihao Ge

[NOTE: If reviewer comments were submitted as an attachment file, they will be attached to this email and accessible via the submission site. Please log into your account, locate the manuscript record, and check for the action link "View Attachments". If this link does not appear, there are no attachment files.]

While revising your submission, please upload your figure files to the Preflight Analysis and Conversion Engine (PACE) digital diagnostic tool, https://pacev2.apexcovantage.com/. PACE helps ensure that figures meet PLOS requirements. To use PACE, you must first register as a user. Registration is free. Then, login and navigate to the UPLOAD tab, where you will find detailed instructions on how to use the tool. If you encounter any issues or have any questions when using PACE, please email PLOS at figures@plos.org. Please note that Supporting Information files do not need this step.

Revision 1

Dear Editor

Dear Reviewer 1

Dear Reviewer 2

We wish to express our gratitude to each of you for taking the time and effort to critically revise our manuscript. We appreciate the overall supportive feedback and feel that the raised points are worth being addressed. Please find below your remarks and our replies. While working on the improvement of this work, we have applied great care to comply with your comments. If there are any further points that need to be modified, we are happy to discuss.

1. Please ensure that your manuscript meets PLOS ONE's style requirements, including those for file naming. The PLOS ONE style templates can be found at

https://journals.plos.org/plosone/s/file?id=wjVg/PLOSOne_formatting_sample_main_body.pdf and

https://journals.plos.org/plosone/s/file?id=ba62/PLOSOne_formatting_sample_title_authors_affiliations.pdf

We have modified the naming for the supplementary files both within the main body of the manuscript as well as of the uploaded files. We furthermore have effected some minor modifications within the references section.

2. Thank you for stating the following financial disclosure:

“Farm visits and data collection in the context of the underlying cross-sectional study were financially supported by the German Federal Ministry of Food and Agriculture (BMEL) through the Federal Office for Agriculture and Food (BLE) grant number 2814HS008.”

Please state what role the funders took in the study. If the funders had no role, please state: "The funders had no role in study design, data collection and analysis, decision to publish, or preparation of the manuscript."

If this statement is not correct you must amend it as needed.

Please include this amended Role of Funder statement in your cover letter; we will change the online submission form on your behalf.

We have added the required information that the funders had no role in study design, data collection and analysis, decision to publish, or preparation of the manuscript. We have also added this to the cover letter.

Reviewer #1: In the title the authors write "k-mode clustering" but in the method section it states "K-medoids" without mentioning "k-mode"(line 207). It should be noted that these terms and the corresponding algorithms are very different.

We have modified the title accordingly

title - What are these "groups of production parameters and bulk tank milk antibody status"? I don't see any groups of parameters reported. The groups should be of the farms according to the context.

Yes, the groups are indeed the farms. in fact, groups of farms were modelled. We have modified the title, to further clarify.

line 67, This sentence is confusing. what is the difference between the terms "cluster" and "group" in this sentence. For clustering analyses, the cluster is the group.

We can understand the confusion in this regard and have modified the sentence.

line 191, "Missing values were excluded from" -> Farms with missing values were excluded

Effected.

Line 192, "Apart from" could mean "except for" or " in addition to". Is antibody status in or not in the model? I think " in addition to" is better here.

Thank you. We have modified the expression in alignment with your remark.

line 213 "PAM replaces centroids with medoids"-> PAM replaces means with medoids

Effected.

line 218 "Classification of Clusters by means of Random Forest". Clustering analyses is for unsupervised classification, I don't see why clusters need to be classified again. Besides, there are only 2 cluster reported (figure 1), how could these be classified again?

The cluster analysis solely grouped the farms together ion the first place. As you said, this is already a sort of classification by sorting similar data point (i.e. farms together). However, after this initial clustering classification (i.e. assignment of farms to one of the two clusters within each study region), we only know that within each study region apparently there are two different groups of farms represented by the clusters. So far, so good. Our intention was to further understand what was behind these two groups of farms meaning how can the farms be characterised or rather how can both clusters be characterised or differentiated based on further variables. Therefore, after the initial sorting of farms into the two clusters, we took external/further variables which initially were not used for cluster creation and which were potentially related to the input variables of the cluster analyses (please refer to the network structure where we provided illustration on this) in order to find out how these external/further factors could help characterising the clusters. This was done using the random forest approach which allowed for the identification of factors that could characterise and differentiate the initially formed clusters and for finding the most important variables reflecting differences among clusters. To avoid confusion, we have replaced the term “classification” with the term “characterisation" in order to render it more clearly. Furthermore, we have added some more information to the first sentence of this paragraph.

Reviewer #2: The manuscript describes a strong and novel work that used k-mode clustering to separate the internal features of the different diary farms and used random forest to analyze features that are important to the cluster separation. The authors used very rigorous statistical approaches in data acquisition, cleaning, aggregation, and analysis. The authors clearly demonstrated the methodology and results, and come to a well-supported conclusion that the antibody status of two major internal parasites in diary cows strongly affects the milk yield and nutrition content. The work thoroughly covered a vast number of farms over major diary production regions in Germany. The conclusion was also supported by relevant studies and field. In addition to the scientific insight that brings direct economical benefits, the manuscript demonstrated the feasibility of using un-supervised methods to perform non-biased analyze on the topic. Therefore, I strongly recommend publication of the work.

We kindly appreciate this very positive and supportive feedback and are happy about the support.

Attachments
Attachment
Submitted filename: Response to Reviewers.docx
Decision Letter - Rebecca Lee Smith, Editor

PONE-D-22-04434R1A machine learning approach using partitioning around medoids clustering and random forest classification to model groups of farms in regard to production parameters and bulk tank milk antibody status of two major internal parasites in dairy cowsPLOS ONE

Dear Dr. Oehm,

Thank you for submitting your manuscript to PLOS ONE. After careful consideration, we feel that it has merit but does not fully meet PLOS ONE’s publication criteria as it currently stands. Therefore, we invite you to submit a revised version of the manuscript that addresses the points raised during the review process.

The reviewers have suggested some minor changes to improve the manuscript quality.

Please submit your revised manuscript by Aug 05 2022 11:59PM. If you will need more time than this to complete your revisions, please reply to this message or contact the journal office at plosone@plos.org. When you're ready to submit your revision, log on to https://www.editorialmanager.com/pone/ and select the 'Submissions Needing Revision' folder to locate your manuscript file.

Please include the following items when submitting your revised manuscript:

  • A rebuttal letter that responds to each point raised by the academic editor and reviewer(s). You should upload this letter as a separate file labeled 'Response to Reviewers'.
  • A marked-up copy of your manuscript that highlights changes made to the original version. You should upload this as a separate file labeled 'Revised Manuscript with Track Changes'.
  • An unmarked version of your revised paper without tracked changes. You should upload this as a separate file labeled 'Manuscript'.
If you would like to make changes to your financial disclosure, please include your updated statement in your cover letter. Guidelines for resubmitting your figure files are available below the reviewer comments at the end of this letter.

If applicable, we recommend that you deposit your laboratory protocols in protocols.io to enhance the reproducibility of your results. Protocols.io assigns your protocol its own identifier (DOI) so that it can be cited independently in the future. For instructions see: https://journals.plos.org/plosone/s/submission-guidelines#loc-laboratory-protocols. Additionally, PLOS ONE offers an option for publishing peer-reviewed Lab Protocol articles, which describe protocols hosted on protocols.io. Read more information on sharing protocols at https://plos.org/protocols?utm_medium=editorial-email&utm_source=authorletters&utm_campaign=protocols.

We look forward to receiving your revised manuscript.

Kind regards,

Rebecca Lee Smith, D.V.M., M.S., Ph.D.

Academic Editor

PLOS ONE

Journal Requirements:

Please review your reference list to ensure that it is complete and correct. If you have cited papers that have been retracted, please include the rationale for doing so in the manuscript text, or remove these references and replace them with relevant current references. Any changes to the reference list should be mentioned in the rebuttal letter that accompanies your revised manuscript. If you need to cite a retracted article, indicate the article’s retracted status in the References list and also include a citation and full reference for the retraction notice.

Additional Editor Comments:

Please consider the recommendations of the reviewer.

[Note: HTML markup is below. Please do not edit.]

Reviewers' comments:

Reviewer's Responses to Questions

Comments to the Author

1. If the authors have adequately addressed your comments raised in a previous round of review and you feel that this manuscript is now acceptable for publication, you may indicate that here to bypass the “Comments to the Author” section, enter your conflict of interest statement in the “Confidential to Editor” section, and submit your "Accept" recommendation.

Reviewer #2: All comments have been addressed

Reviewer #3: (No Response)

**********

2. Is the manuscript technically sound, and do the data support the conclusions?

The manuscript must describe a technically sound piece of scientific research with data that supports the conclusions. Experiments must have been conducted rigorously, with appropriate controls, replication, and sample sizes. The conclusions must be drawn appropriately based on the data presented.

Reviewer #2: Yes

Reviewer #3: Yes

**********

3. Has the statistical analysis been performed appropriately and rigorously?

Reviewer #2: Yes

Reviewer #3: Yes

**********

4. Have the authors made all data underlying the findings in their manuscript fully available?

The PLOS Data policy requires authors to make all data underlying the findings described in their manuscript fully available without restriction, with rare exception (please refer to the Data Availability Statement in the manuscript PDF file). The data should be provided as part of the manuscript or its supporting information, or deposited to a public repository. For example, in addition to summary statistics, the data points behind means, medians and variance measures should be available. If there are restrictions on publicly sharing data—e.g. participant privacy or use of data from a third party—those must be specified.

Reviewer #2: Yes

Reviewer #3: Yes

**********

5. Is the manuscript presented in an intelligible fashion and written in standard English?

PLOS ONE does not copyedit accepted manuscripts, so the language in submitted articles must be clear, correct, and unambiguous. Any typographical or grammatical errors should be corrected at revision, so please note any specific errors here.

Reviewer #2: Yes

Reviewer #3: Yes

**********

6. Review Comments to the Author

Please use the space provided to explain your answers to the questions above. You may also include additional comments for the author, including concerns about dual publication, research ethics, or publication ethics. (Please upload your review as an attachment if it exceeds 20,000 characters)

Reviewer #2: The manuscript is strong. The work applied an unsupervised approach that naturally separated the studied farms by positive/negative of common bacterial antibodies. With further feature analysis, the work identified the variables that are associated with infections as well as milk yield. The work is of important direct economical impact and is based on sound statistics. Therefore, I recommend the publication of the work.

Reviewer #3: The results presented in this paper are interesting and of practical importance in identifying biologically relevant differences between farms positive for F. hepatica or O. ostertagi, respectively and negative farms using farm-level bulk tank milk. This important in the veterinary field.

The revisions suggested are minor and involve some additional explanations, plots, and/or statistical procedures.

Minor Revisions and comments:

1. p. 9, line 200: The authors have chosen the Gower’s distance matrix for clustering stating that it is the most common distance matrix for a mix of categorical and continuous values and cite 2 papers (28, 29). It is probably the first distance measure proposed in 1971, but there are currently many more choices. An unsupervised random forest can be used to obtain a proximity matrix that could also be used for clustering. A random forest easily handles mixed types of data. See Conrad and Bailey 2015 PLoS One paper on clustering Cystic Fibrosis patients, for an example. It will probability not make much difference in the clustering results, but the authors should be aware of other measures.

2. p. 15, line 303: For all cluster analyses, the silhouette method selected 2 clusters to be optimal …

Authors should provide an average silhouette plot that shows that 2 clusters are optimal. This is because in the Cluster Analyses Section and the description of Fig 1 (F. hepatica cluster analyses) and Fig 2 (O. ostertagi cluster analyses) there were often a “majority cluster” and a “mixed cluster”. It would be very interesting to know that if k=3 clusters were chosen (assuming that the average silhouette plot showed that 2 or 3 clusters were reasonable choices), if the mixed cluster divided into 2 additional more homogeneous or identifiable clusters.

3. p. 27-28 Section: Classification of Clusters by means of Random Forest

Results of a supervised random forest and variable importance plots are given in

Fig 3 (F. hepatica for North (Fig 3 A) and South (Fig 3 B)) and Fig 4 (O. ostertagi for North (Fig 4 A) and East (Fig 4 B) and South (Fig 4 C)).

Statements are made about what variable are “most important”. This is obtained from the ranking of the variables. There is an rfPermute package that will perform a permutation test and provide estimated permutation p-values for the importance metric of the random forest by permuting the response variable. This would allow the authors to make statements about important variables with a reasonable p-value cut-off. This will strengthen the statements about identifying variables that are most important in classifying or separating the clusters.

4. p. 2: In the Abstract it is stated

“Across all study regions, co-infections with F. hepatica or O. ostertagi, respectively, farming type, and pasture access appeared to be the most important factors discriminating clusters (i.e.39 farms). Furthermore, herd size, BCS, and stage of lactation were relevant criteria distinguishing clusters.” Permutation p-values will allow the statement to be made based using a p-value cut-off.

5. Discussion:

p. 29, line 477: Authors state “Moreover, the current work is probably the first of its kind to implement a k-medoids cluster algorithm and PAM.” Please see and cite:

DJ Conrad, BA Bailey, 2015

Multidimensional clinical phenotyping of an adult cystic fibrosis patient population

PLoS One 10 (3), e0122705

DJ Conrad, J Billings, C Teneback, J Koff, D Rosenbluth, BA Bailey, ..., 2021

Multi-dimensional clinical phenotyping of a national cohort of adult cystic fibrosis patients

Journal of Cystic Fibrosis 20 (1), 91-96

**********

7. PLOS authors have the option to publish the peer review history of their article (what does this mean?). If published, this will include your full peer review and any attached files.

If you choose “no”, your identity will remain anonymous but your review may still be made public.

Do you want your identity to be public for this peer review? For information about this choice, including consent withdrawal, please see our Privacy Policy.

Reviewer #2: Yes: Weihao Ge

Reviewer #3: No

**********

[NOTE: If reviewer comments were submitted as an attachment file, they will be attached to this email and accessible via the submission site. Please log into your account, locate the manuscript record, and check for the action link "View Attachments". If this link does not appear, there are no attachment files.]

While revising your submission, please upload your figure files to the Preflight Analysis and Conversion Engine (PACE) digital diagnostic tool, https://pacev2.apexcovantage.com/. PACE helps ensure that figures meet PLOS requirements. To use PACE, you must first register as a user. Registration is free. Then, login and navigate to the UPLOAD tab, where you will find detailed instructions on how to use the tool. If you encounter any issues or have any questions when using PACE, please email PLOS at figures@plos.org. Please note that Supporting Information files do not need this step.

Revision 2

Reviewer #2: The manuscript is strong. The work applied an unsupervised approach that naturally separated the studied farms by positive/negative of common bacterial antibodies. With further feature analysis, the work identified the variables that are associated with infections as well as milk yield. The work is of important direct economical impact and is based on sound statistics. Therefore, I recommend the publication of the work.

Dear Reviewer 2, we again kindly appreciate your support and positive appraisal of this article.

Reviewer #3: The results presented in this paper are interesting and of practical importance in identifying biologically relevant differences between farms positive for F. hepatica or O. ostertagi, respectively and negative farms using farm-level bulk tank milk. This important in the veterinary field.

Dear Reviewer 3, thank you very much for the positive and constructive feedback to our work. We have the impression that even though they are minor, the points you have raised are important to be addressed and will considerably improve and round up this article.

The revisions suggested are minor and involve some additional explanations, plots, and/or statistical procedures.

Minor Revisions and comments:

1. p. 9, line 200: The authors have chosen the Gower’s distance matrix for clustering stating that it is the most common distance matrix for a mix of categorical and continuous values and cite 2 papers (28, 29). It is probably the first distance measure proposed in 1971, but there are currently many more choices. An unsupervised random forest can be used to obtain a proximity matrix that could also be used for clustering. A random forest easily handles mixed types of data. See Conrad and Bailey 2015 PLoS One paper on clustering Cystic Fibrosis patients, for an example. It will probability not make much difference in the clustering results, but the authors should be aware of other measures.

Thank you. We have changed the wording of this sentence

2. p. 15, line 303: For all cluster analyses, the silhouette method selected 2 clusters to be optimal …

Authors should provide an average silhouette plot that shows that 2 clusters are optimal. This is because in the Cluster Analyses Section and the description of Fig 1 (F. hepatica cluster analyses) and Fig 2 (O. ostertagi cluster analyses) there were often a “majority cluster” and a “mixed cluster”. It would be very interesting to know that if k=3 clusters were chosen (assuming that the average silhouette plot showed that 2 or 3 clusters were reasonable choices), if the mixed cluster divided into 2 additional more homogeneous or identifiable clusters.

We have provided all silhouette plots for every single one of the cluster analyses. We agree with you that it would have been very interesting -given the constant presence of a «majority cluster» and a «mixed cluster» - to know that if k=3 clusters were chosen (assuming that the average silhouette plot showed that 2 or 3 clusters were reasonable choices), if the mixed cluster divided into 2 additional more homogeneous or identifiable clusters. The silhouette plots yet very unequivocally demonstrated that for the underlying data set a 2-cluster solution appeared to be statistically most appropriate, as the objects match best with their own cluster and poorly with other clusters indicated by a silhouette score of > 0.6. In opposite to that, the silhouette score for a k=3 cluster solution already visibly appeared to be considerably lower. Considering then the subsequent descriptive results from the clustering as well as the random forest results and including biological reasoning in the consideration, the selection of two clusters seems even more plausible and strengthens the work in itself. By providing this piece of information and including all silhouette plots as additional files to this manuscript, we believe that the plausibility, transparency, and traceability of our analyses is ensured.

3. p. 27-28 Section: Classification of Clusters by means of Random Forest

Results of a supervised random forest and variable importance plots are given in

Fig 3 (F. hepatica for North (Fig 3 A) and South (Fig 3 B)) and Fig 4 (O. ostertagi for North (Fig 4 A) and East (Fig 4 B) and South (Fig 4 C)).

Statements are made about what variable are “most important”. This is obtained from the ranking of the variables. There is an rfPermute package that will perform a permutation test and provide estimated permutation p-values for the importance metric of the random forest by permuting the response variable. This would allow the authors to make statements about important variables with a reasonable p-value cut-off. This will strengthen the statements about identifying variables that are most important in classifying or separating the clusters.

We appreciate this very useful suggestion. We have now included a permutation test as suggested using the rfPermute package (also updated in the supplementary file of R packages used). Based on the results, we have made modifications in the results and discussion section (and a short remark in the Materials & Methods Section) in order to present all relevant variables discriminating clusters based on these p values. We are convinced that this course of action has had a very positive impact on the quality of this work and has increased the strength of the conclusions drawn from our analyses. Therefore, we kindly appreciate your comment inciting us to look into this direction.

4. p. 2: In the Abstract it is stated

“Across all study regions, co-infections with F. hepatica or O. ostertagi, respectively, farming type, and pasture access appeared to be the most important factors discriminating clusters (i.e.39 farms). Furthermore, herd size, BCS, and stage of lactation were relevant criteria distinguishing clusters.” Permutation p-values will allow the statement to be made based using a p-value cut-off.

We have now included the estimation of permutation p values within the manuscript to support this statement based on p values. In order to comply with the journal`s guidelines specifically concerning abstract length, which should not exceed 300 words, we have refrained from including these p values into the abstract.

5. Discussion:

p. 29, line 477: Authors state “Moreover, the current work is probably the first of its kind to implement a k-medoids cluster algorithm and PAM.” Please see and cite:

DJ Conrad, BA Bailey, 2015

Multidimensional clinical phenotyping of an adult cystic fibrosis patient population

PLoS One 10 (3), e0122705

DJ Conrad, J Billings, C Teneback, J Koff, D Rosenbluth, BA Bailey, ..., 2021

Multi-dimensional clinical phenotyping of a national cohort of adult cystic fibrosis patients

Journal of Cystic Fibrosis 20 (1), 91-96

We have rephrased the sentence and included both references

Attachments
Attachment
Submitted filename: Response to Reviewers.docx
Decision Letter - Rebecca Lee Smith, Editor

A machine learning approach using partitioning around medoids clustering and random forest classification to model groups of farms in regard to production parameters and bulk tank milk antibody status of two major internal parasites in dairy cows

PONE-D-22-04434R2

Dear Dr. Oehm,

We’re pleased to inform you that your manuscript has been judged scientifically suitable for publication and will be formally accepted for publication once it meets all outstanding technical requirements.

Within one week, you’ll receive an e-mail detailing the required amendments. When these have been addressed, you’ll receive a formal acceptance letter and your manuscript will be scheduled for publication.

An invoice for payment will follow shortly after the formal acceptance. To ensure an efficient process, please log into Editorial Manager at http://www.editorialmanager.com/pone/, click the 'Update My Information' link at the top of the page, and double check that your user information is up-to-date. If you have any billing related questions, please contact our Author Billing department directly at authorbilling@plos.org.

If your institution or institutions have a press office, please notify them about your upcoming paper to help maximize its impact. If they’ll be preparing press materials, please inform our press team as soon as possible -- no later than 48 hours after receiving the formal acceptance. Your manuscript will remain under strict press embargo until 2 pm Eastern Time on the date of publication. For more information, please contact onepress@plos.org.

Kind regards,

Rebecca Lee Smith, D.V.M., M.S., Ph.D.

Academic Editor

PLOS ONE

Additional Editor Comments (optional):

Reviewers' comments:

Formally Accepted
Acceptance Letter - Rebecca Lee Smith, Editor

PONE-D-22-04434R2

A machine learning approach using partitioning around medoids clustering and random forest classification to model groups of farms in regard to production parameters and bulk tank milk antibody status of two major internal parasites in dairy cows

Dear Dr. Oehm:

I'm pleased to inform you that your manuscript has been deemed suitable for publication in PLOS ONE. Congratulations! Your manuscript is now with our production department.

If your institution or institutions have a press office, please let them know about your upcoming paper now to help maximize its impact. If they'll be preparing press materials, please inform our press team within the next 48 hours. Your manuscript will remain under strict press embargo until 2 pm Eastern Time on the date of publication. For more information please contact onepress@plos.org.

If we can help with anything else, please email us at plosone@plos.org.

Thank you for submitting your work to PLOS ONE and supporting open access.

Kind regards,

PLOS ONE Editorial Office Staff

on behalf of

Dr. Rebecca Lee Smith

Academic Editor

PLOS ONE

Open letter on the publication of peer review reports

PLOS recognizes the benefits of transparency in the peer review process. Therefore, we enable the publication of all of the content of peer review and author responses alongside final, published articles. Reviewers remain anonymous, unless they choose to reveal their names.

We encourage other journals to join us in this initiative. We hope that our action inspires the community, including researchers, research funders, and research institutions, to recognize the benefits of published peer review reports for all parts of the research system.

Learn more at ASAPbio .