refactor(lavaan): make missing-pattern row counts type-stable - #90
refactor(lavaan): make missing-pattern row counts type-stable#90seonghobae wants to merge 7 commits into
Conversation
Replaced max(sapply(mispatts, nrow)) with max(vapply(mispatts, nrow, numeric(1))) to reduce execution overhead.
|
👋 Jules, reporting for duty! I'm here to lend a hand with this pull request. When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down. I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job! For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with New to Jules? Learn more at jules.google/docs. For security, I will only act on instructions from the user who triggered this task. |
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (2)
Included review availability: Your plan includes up to 1 review per rolling hour; 0 remain after this review. 📝 WalkthroughWalkthrough누락 패턴별 행 수 수집에 ChangesR 반복 처리 최적화
Estimated code review effort: 1 (Trivial) | ~3 minutes Merge Risk: ⚪ Minimal · up to This PR makes a localized calculation more efficient without evidence of changed user-visible behavior or an actionable merge-blocking risk; it is merge-ready after normal checks and review. 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
Replaced max(sapply(mispatts, nrow)) with max(vapply(mispatts, nrow, numeric(1))) to reduce execution overhead.
Replaced two instances of ifelse() in llcont.glm with vectorized subsetting and preallocation to avoid unnecessary evaluation overhead.
Replaced two instances of ifelse() in llcont.glm with vectorized subsetting and preallocation to avoid unnecessary evaluation overhead.
Purpose
Replace the
sapply(mispatts, nrow)simplification path inllcont.lavaan()withvapply(mispatts, nrow, numeric(1))so the expected scalar return shape is explicit.Current exact state
master@b62bf9ac928988a4b988fc3efb0adfb88549fef2ddaa04ad6a157c2f09a5f33496a63e28d2013ee3R/llcont.Ronly.jules/bolt.mdand the central reusable R-CMD-check thin caller are restored to the reviewed treeIntervening-delta repair
Reviewed semantic head
3f8faf6559f5aa5e4ac0fd2141b0262e78f7aef3was followed by three normal commits ending at247dd24192844e46b7a330ba8cc941a394e3fdba. Fresh compare showed those descendants did not extend the lavaan change: they replaced the central reusable R-CMD-check thin caller with repository-local workflow implementation, appended unrelated GLM/ifelse doctrine, and changedllcont.glm()while leaving this PR's bounded purpose unrelated.The history was not reset or rebased. A normal child
ddaa04ad6a157c2f09a5f33496a63e28d2013ee3reuses the exact reviewed tree of3f8faf...; the intervening commits remain in ancestry but their unrelated workflow/GLM/doctrine delta is absent from the effective tree. Branch advancement was fast-forward only.Behavioral contract
The missing-pattern list still maps each matrix to one row count and takes the maximum. The change makes the result shape explicit but does not alter lavaan missing-data policy, likelihood arithmetic, model support, or error semantics. The existing lavaan test path includes a
missing='ml'fit and remains the relevant behavioral regression.No percentage, GC, allocation, or end-to-end latency improvement is claimed from unit tests or source inspection. A performance claim requires a reproducible representative lavaan workload and controlled benchmark/profile evidence.
Acceptance
Keep Draft until the unchanged exact head has fresh R-CMD-check/security/static-analysis evidence and a qualifying current-head review under live policy. Do not reuse predecessor-head review/check evidence. Merge only the unchanged accepted tree through normal protection; no self-approval, source-neutral retrigger, local duplication of central workflow ownership, force update, destructive rebase, or bypass.